[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] character encoding with MSXML3
Hi xsl-list'ers, I am creating HTML documents that are bilingual (English and French) (i.e. using <xsl:output method="html">). I successfully have Saxon putting out those special HTML Latin characters (e.g. é) for my French output. I do not have such success with Microsoft. It puts out the actual small e acute -- what you get when you type ALT-130 on a Windows box in notepad. Unfortunately for now, I am stuck with Microsoft's MSXML parser. Does anyone know if there is a setting in Microsoft's parser to get it to put out "é"? Or perhaps I am missing something in my xsl:stylesheet declaration? (BTW: The XSLT Test tool is a great way to quickly compare output between different XSL implementations. http://www.netcrucible.com/xslt/xslt-tool.htm ) Thanks. My XML (note the encoding is ISO not UTF) --------------- <?xml version="1.0" encoding="ISO-8859-1"?> <dtdTest> <ENGLISH_MENU>Client Statements</ENGLISH_MENU> <FRENCH_MENU>Relevés clients</FRENCH_MENU> </dtdTest> My XSL --------------- <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output method="html"/> <xsl:template match="/"> <html> <xsl:apply-templates select="dtdTest"/> </html> </xsl:template> <xsl:template match="dtdTest"> <body> <xsl:apply-templates/> </body> </xsl:template> <xsl:template match="ENGLISH_MENU"> <xsl:value-of select="."/> </xsl:template> <xsl:template match="FRENCH_MENU"> <xsl:value-of select="."/> </xsl:template> </xsl:stylesheet> My happy output using Saxon --------- <html> <body> Client Statements Relevés clients </body> </html> My less happy Microsoft output (apologies to all whose systems have munged the e-acute below) -------- <html> <body> Client Statements Relevés clients </body> </html> James MacEwan Software Developer Investors Group Inc. mailto:James.MacEwan@xxxxxxxxxxxxxxxxxx v: (204) 956-8515 f: (204) 943-3540 "I don't know, lad. It's like no cheese I've ever tasted." -- Wallace XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|