[Home] [By Thread] [By Date] [Recent Entries]
G. Ken Holman wrote:
At 2009-02-17 20:20 +0300, P!P>P;P>P2QP5P2 PP=P4QP5P9 wrote:Hi. I have such XSLT code: ... <br/> <img src="test.jpg"/> ... The html output method applies to HTML elements in no namespace while the posted stylesheet had <xsl:stylesheet version="1.0" xmlns="http://www.w3.org/1999/xhtml" xmlns:php="http://php.net/xsl" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> so it creates its result elements in the XHTML namespace http://www.w3.org/1999/xhtml and for those the html output method does not apply so the processor is free to serialize as e.g. <br></br>. To the original poster: I don't think there is a good solution as long as you are trying to create XHTML (to be served as text/html) with an XSLT 1.0 processor. XSLT 2.0 has an output method 'xhtml' which should do what you want but XSLT 1.0 processors like libxslt do not support that I think. You can make your life a lot easier by changing your XSLT stylesheet to create HTML 4 documents instead as then the html output method applies. -- Martin Honnen http://JavaScript.FAQTs.com/
|

Cart



