GNOME Bugzilla – Bug 322870
XHTML serialization for XHTML 1.1
Last modified: 2012-11-03 15:58:37 UTC
See the discussion here: http://mail.gnome.org/archives/xslt/2003-December/msg00047.html XHTML 1.1 is currently serialized as XML, without any XHTML fixups. It would be nice if XHTML 1.1 would be treated like XHTML 1.0.
Created attachment 57351 [details] [review] Proposed patch Adds support for XHTML 1.1 and XHTML 2.0
I don't think that's sufficient. In the case of XHTML-1.0 it was designed to be standalone, i.e. not extensible just a backport of HTML-4.01 . However XHTML-1.1 and later are expected to be compounded, the fact that you have a XHTML DOCTYPE doesn't prevent other elements from other namespaces to be added. What are the serialization rules for them ? I assume there is none. However the current xhtml serialization routines assume the namespace of the elements are the xhtml one. if this isn't the case, for exampel if there is a element named 'script' in another namespace embedded then it will get the special processing. So adding specific sedialization rules for the modular XHTML can only be enabled once the xhtml serialization routines will also check the namespaces. As is the patch open the door to real problems at the XML level, I don't think it's a good idea to apply it, extra checking code will be needed in the xhtml*Dump* routines. Daniel
I see. XHTML 1.1 and beyond isn't designed to be backwards compatible with HTML. So the serialization quirks aren't needed.