Subject: Re: [xsl] encoding issues From: David Carlisle <davidc@xxxxxxxxx> Date: Wed, 3 Jul 2002 13:30:53 +0100 |
> How can you be sure? You can never be sure of anything. An XSLT processor is explictly allowed to ignore the requested output and use an output encoding of its choice. For example MSXML always does this if you output to a string rather than to a file, or equivalently if you output to a DOM tree then there is no output encoding at all (as it's not output in that sense) so if you later serialise that dom you get whatever _that_ serialisation asks for, not what was in the xsl:output. In the html output method this doesn't matter so much because the system adds the <meta element and will specify in there whatever encoding it really used. In the xml output method the best you can do is output a meta element that specifies the output encoding you requested, but if the system chooses a different encoding it will not change the meta element to match, as the xml output method just sees <meta as a normal element that happens to be in the result tree. In practice if you are targeting something specific like msxml you can tell what output encoding will be used: either it obeys the requested one from xsl:output or it always uses utf16, depending how it is called. It would be legal for an XSLT system to change it's behaviour depending on the time of day, but few if any do. David _____________________________________________________________________ This message has been checked for all known viruses by Star Internet delivered through the MessageLabs Virus Scanning Service. For further information visit http://www.star.net.uk/stats.asp or alternatively call Star Internet for details on the Virus Scanning Service. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] encoding issues, Andrew Welch | Thread | Re: [xsl] encoding issues, Mike Brown |
RE: [xsl] encoding issues, Andrew Welch | Date | Re: [xsl] xsl-fo question, G. Ken Holman |
Month |