This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: FW: ] Top Ten Java and XSLT Tips, #5


> > that's what you see if you look at the utf8 encoding of the 
> > character in a latin1 encoded window.
> > 
> > IE5 on windows will only do that if you set it up wrong: 
> > forcing it to use the latin1 encoding even if the document 
> > specifies utf8.
> > 
> > Much as I'd prefer to blame microsoft I suspect user error in 
> > this case.
> 
> It doesn't work on IE6 final either. At least the final I have here. It
> displays   as A^  AND for some reason all of the encodings are
> greyed out and the only one available is western encoding (windows). 

It works perfectly with IE6, but you should generate a META tag with the right
encoding as Julian Reschke correctly suggested.

The following stylesheet when applied on any xml input will produce output, which is
correctly displayed by IE6.

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
    <xsl:output method="xml" encoding="UTF-8"/>
    <xsl:template match="/">
      <html>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>

        <test>
          test1<xsl:text>&#160;</xsl:text>test2
        </test>
      </html>
    </xsl:template>
</xsl:stylesheet>

The output produced is displayed by IE6 as:

test1 test2 


Cheers,
Dimitre Novatchev.

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]