NOTE: The current preferred location for bug reports is the GitHub issue tracker.
Bug 1032 - HtmlSerializer: use of localName without checking namespace
HtmlSerializer: use of localName without checking namespace
Status: NEW
Product: Validator.nu
Classification: Unclassified
Component: HTML parser
HEAD
All All
: P2 minor
Assigned To: Nobody
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2016-12-14 11:24 CET by Tim Starling
Modified: 2016-12-14 11:24 CET (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Starling 2016-12-14 11:24:48 CET
Elements with the local name "pre", "textarea", "listing", the void elements, and the non-escaping elements, should all be treated specially by HtmlSerializer only if the element's namespace is the HTML namespace. For example:

<math><track/></math>

This should be reserialized as:

<math><track></track></math>

As the standard says: "As stated in the terminology section, references to element types that do not explicitly specify a namespace always refer to elements in the HTML namespace. For example, if the spec talks about "a menuitem element", then that is an element with the local name "menuitem", the namespace "http://www.w3.org/1999/xhtml", and the interface HTMLMenuItemElement."

Let me know if you want a patch.