Subject: RE: [xsl] xsl:output and xsl:result-document From: "Michael Kay" <mike@xxxxxxxxxxxx> Date: Tue, 15 Sep 2009 17:46:03 +0100 |
> Thanks Martin and Andrew - these are both helpful > suggestions. As it turned out in my case, I was able to > output text while declaring it to be xml: I didn't think this > would work, but apparently at least Saxon will allow you to > output an xml document that contains only text: no elements, > which is just what I needed. If you use disable-output-escaping="yes" and omit-xml-declaration="yes" (and don't output any elements) then yes, the XML output method becomes very close to the text output method. But it seems clearer to use method="text", and there is nothing that stops you using different output methods for different result documents. And relying on disable-output-escaping seems very error prone - the first time you encounter data containing "<" or "&", you're going to find that you forgot to put d-o-e on the relevant xsl:value-of instruction. Regards, Michael Kay http://www.saxonica.com/ http://twitter.com/michaelhkay
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] xsl:output and xsl:result, David Carlisle | Thread | Re: [xsl] xsl:output and xsl:result, Mike Sokolov |
Re: [xsl] xsl:output and xsl:result, David Carlisle | Date | Re: [xsl] xsl:output and xsl:result, Mike Sokolov |
Month |