You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by bu...@apache.org on 2002/02/27 17:39:19 UTC
DO NOT REPLY [Bug 6724] New: -
UTF-8 encoded style sheet fails to compile.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6724>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6724
UTF-8 encoded style sheet fails to compile.
Summary: UTF-8 encoded style sheet fails to compile.
Product: XalanJ2
Version: CurrentCVS
Platform: PC
OS/Version: Windows NT/2K
Status: NEW
Severity: Major
Priority: Other
Component: org.apache.xalan.xsltc
AssignedTo: xalan-dev@xml.apache.org
ReportedBy: mike_counsell@hp.com
I have a UTF-8 encoded style sheet that fails to compile, below is the output
from the XSLT compiler:
Compiler error(s):
file:/C:/problem.xsl: line 7: Required attribute 'select' is missing.
file:/C:/problem.xsl: line 9: Required attribute 'select' is missing.
If I remove the non ASCII chars from the select attribute of the
xsl:value-of element then the compile succeeds. This style sheet works with the
regular Xalan XSLT processor.
At first I thought that the issue was due to the compiler reading the file with
a default character encoding, so I got the latest code from the CVS and
attempted to fix this in a hope to submit a fix. However it seems that this is
not the case since even when the InputSource from the style sheet contains the
correct character encoding, the compilation still fails.
I've coped the style sheet below but I am not confident that the character
encoding will be faithfully maintained on the server side. Hence please contact
me mike_counsell@hp.com for the original document.
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" >
<xsl:output method="xml" indent="yes"/>
<xsl:template match="/">
<html>
<body>
<xsl:value-of select="/Quiz_Question/���ē�"/>
<select name="answer" value="1" >
<xsl:for-each select="Quiz_Question/��
��/Answer">
<xsl:element name="option">
<xsl:attribute
name="value"><xsl:value-of select="ID"/></xsl:attribute>
<xsl:value-of select="Name"/>
</xsl:element>
</xsl:for-each>
</select>
</body>
</html>
</xsl:template>
</xsl:stylesheet>