Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

175
Views
When do browsers reject invalid html? Especially when dynamically created

Modern browsers routinely fix invalid html by rearranging elements in the DOM, but when you create the same html-structure with JavaScript, it remains intact. Why? This seems consistent across browsers. Is there a W3C recommendation how such cases should be handled? Under what circumstances can we expect browsers to intervene?

For examples, see the following JSFiddle: https://jsfiddle.net/od0uwxsb/

It includes span-Elements in place of td-Elements and table-Elements inside p-nodes. In both cases browsers fix the invalid html in the initial load, but keep it intact when the structure is created dynamically.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!