GNOME Bugzilla – Bug 53402
Output of xsl:processing-instruction
Last modified: 2009-08-15 18:40:50 UTC
<xsl:processing-instruction name="php">test</xsl:processing-instruction> generates: <php>test</php> when I think it should really be: <?php test ?>
Hum, I can't reproduce it with the CVS version, orchis:~/XSLT/tests/general -> cat bug-9-.xsl <?xml version= "1.0"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:template match="/"> <xsl:processing-instruction name="php">Success</xsl:processing-instruction> </xsl:template> </xsl:stylesheet> orchis:~/XSLT/tests/general -> cat ../docs/bug-9-.xml <?xml version= "1.0"?> <doc/> orchis:~/XSLT/tests/general -> xsltproc bug-9-.xsl ../docs/bug-9-.xml <?xml version="1.0"?> <?php Success?> orchis:~/XSLT/tests/general -> Even the 0.7.0 released version seems to behave correctly: orchis:~/XSLT/tests/general -> /usr/bin/xsltproc bug-9-.xsl ../docs/bug-9-.xml <?xml version="1.0"?> <?php Success?> orchis:~/XSLT/tests/general -> rpm -qf /usr/bin/xsltproc libxslt-0.7.0-1 orchis:~/XSLT/tests/general -> Unless you can provide more context on the bug I consider it closed Daniel
After further investigations, the problem appears when you use an in the stylesheet (my stylesheet was importing another stylesheet using this output method). Don't know if this is a bug, I don't understand clearly the recommandation on this point. Xalan didn't change the output of xsl:processing-instruction with method "html", though. On a related note, I have noticed that importing a stylesheet containing does not output the directly in the first stylesheet produces the doctype header as a result. Anyway, thanks again for your work and quick answers, I think I can use libxslt instead of xalan now :-) (and I'll update libxml2 and libxslt packages as soon as our cluster is back ;-) Renaud
Okay can you give me the inputs needed for this testcase ? I understand there is 3 files needed: - the main stylesheet - the imported stylesheet - the document processed They may be small but if I have a clear testcase this speeds my work a lot, thanks in advance Daniel
After double checking directly, this seems to fix the bug Daniel