http://nagoya.apache.org/bugzilla/show_bug.cgi?id=1950

*** shadow/1950 Sat Jul 21 00:46:04 2001
--- shadow/1950.tmp.10497       Sat Jul 21 00:59:12 2001
***************
*** 80,82 ****
--- 80,123 ----
  ------- Additional Comments From [EMAIL PROTECTED]  2001-07-21 00:46 -------
  Created an attachment (id=346)
  Source of test program to perform Xsl transformation
+ 
+ 
+ ------- Additional Comments From [EMAIL PROTECTED]  2001-07-21 00:59 -------
+ Sorry about the late reply..
+ 
+ Enclose is a sample XML file in BIG5 encoding.
+ 
+ <?xml version="1.0" encoding="BIG5"?>
+ <aaa>
+   <bbb>­» ´ä ©~ ¥Á</bbb>
+ </aaa>
+ 
+ And here is the XSL file I used,
+ 
+ <?xml version="1.0" encoding="BIG5"?>
+ <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
+ <xsl:output method="html" encoding="BIG5"/>
+ <xsl:template match="/aaa">
+   And the value of bbb is: <xsl:value-of select="bbb"/>
+ </xsl:template>
+ </xsl:stylesheet>
+ 
+ With the attached test program, the output result will be:-
+ 
+ $ java JaxpTest2 big5.xml testing.xsl
+ Transformation ....
+      And the value of bbb is: &shy;&raquo; &acute;&auml; &copy;~ &yen;&Aacute;
+ 
+ All the BIG5 Chinese characters are escaped. However, if I read the xml and xsl 
+ files in as StreamSource, the output will not be escaped as in the above case. 
+ Alternatively, I can use the disable-output-escaping attribute, i.e.
+ 
+   And the value of bbb is: <xsl:value-of select="bbb" disable-output-
+ escaping="yes"/>
+ 
+ and the output result will also be fine. However, this is hardly the most 
+ desirable approach. Another way we have found to get around the problem is to 
+ edit the org/apache/xalan/serialize/HTMLEntities.res resource file, remove all 
+ the escape reference from 161 onward and rebuild xalan.
+ 
+ Hope the above information is useful in solving the bug.

Reply via email to