[webkit-help] XSLTProcessor: transformToFragment returns HTMLElement even with method="xml"

Gregoire webkit-help at artefarita.com
Sun Sep 12 15:40:41 PDT 2010


Hi Alexey,

Thank you very much for your quick and informative answer. You're right
about the xmlns attribute on line 84 : removing it fixes the problem.
I've told Alain Couthures (XSLTForms developper) about the
"xsltforms.xsl" problem with these attributes so maybe it will be fixed
there too.

Hopefully Safari and Chrome will include the HTML5 parser improvements soon.

Best regards,
Grégoire

Le 12/09/2010 20:14, Alexey Proskuryakov a écrit :
> 
> 12.09.2010, в 06:36, Gregoire написал(а):
> 
>> I've created a test-case so that it is easier to answer my question.
> 
> 
> This is a combination of a WebKit bug, and a mistake in xsltforms.xsl.
> 
> The WebKit bug has been fixed last month as part of HTML5 parser compliance effort, you can see that your test case works as expected in WebKit nightlies <http://nightly.webkit.org>.
> 
> The xsltforms.xsl problem is that it produces an HTML document with lots of pseudo-XML cruft in it, which used to confuse WebKit. Notably, on line 84 it outputs '<html xmlns="http://www.w3.org/1999/xhtml">' - removing the default namespace fixes the problem in Safari 5.0.2.
> 
> I'm attaching the result an XSL processor gives for test-chrome-xslt.xml for your reference. You can see garbage xmlns attributes on <html>, <script> and <dataisland> - these serve no purpose when output="html" (as it is in xsltforms.xsl).
> 
> 
> 
> 
> 
> - WBR, Alexey Proskuryakov
> 



More information about the webkit-help mailing list