[Bug 20201] polyglot markup and extensions via <script> (and <style>)

https://www.w3.org/Bugs/Public/show_bug.cgi?id=20201

Leif Halvard Silli <xn--mlform-iua@xn--mlform-iua.no> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |xn--mlform-iua@xn--mlform-i
                   |                            |ua.no

--- Comment #2 from Leif Halvard Silli <xn--mlform-iua@xn--mlform-iua.no> ---
(In reply to comment #1)
> No, it can't. Design goal of polyglot is to produce same DOM when content is
> parser by either XML or HTML parser. HTML parser produces one text node from
> the content of <script> element even if the content is XML fragment. XML
> parser will parse content of <script> as any other element producing correct
> DOM subtree from XML fragment.

OK. Tested. And saw that you are right. So then I think that there are 3
options:

1 EITHER the polyglot spec should describe how to circumvent these restriction
  by converting the content of <script> to a data URI.

2 OR the polyglot spec should carve out an exception from the principles, and
  allow CDATA inside SCRIPT. The *would* permit very similar DOMs. Except that
  in XHTML there would be a CDATA node, while in HTML there would not.

3 OR, for script/style, skip the "DOMs must be identical" rules.

CONCLUSION: In order to not touch the design principles, I ask the editor add
            to the spec a description of the first option (data URIs).

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Monday, 3 December 2012 13:25:26 UTC