character maps in stylesheets used by Xalan fail
------------------------------------------------

                 Key: XALANJ-2529
                 URL: https://issues.apache.org/jira/browse/XALANJ-2529
             Project: XalanJ2
          Issue Type: Bug
      Security Level: No security risk; visible to anyone (Ordinary problems in 
Xalan projects.  Anybody can view the issue.)
          Components: Serialization
         Environment: Linux  2.6.5-7.151-s390x (SuSE mainframe) and 2.6.23.9lw 
#105 SMP (Red Hat derived Intel)
            Reporter: David Collier-Brown


I send a file containing the line
--
character="✓" name="check;"
--
to Xerces, and wrote it to the following xsl program:
---
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
   version="2.0">

  <xsl:output
        use-character-maps="cm1" />

  <xsl:character-map name="cm1">
      <xsl:output-character character="&#10003;" string="&amp;check;"/>
  </xsl:character-map>
</xsl:stylesheet>
--

The output, alas, is 
--
character="&#10003;" name="check;"
--
where "&#10003;" is literally a checkmark character. Piping it through
cat -A yeilds
--
character="M-bM-^\M-^S" name="check;"$
--

I expected a literal ampersand followed by "check;", but instead got a 
literal checkmark on both mainframe and intel linux.

The code example is from www.xml.com/lpt/a/1426, and has arguably
worked for the author, but but several other commentartors suggest it 
doesn't work, as found via the google search "xsl character-map doesn't work"

This is puzzling, and disqualifies me from using Xerces, and even DOm in
in general for my customer.

Is there a general problem with character maps, or ones specific to particular 
implementations?

--dave


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscr...@xml.apache.org
For additional commands, e-mail: xalan-dev-h...@xml.apache.org

Reply via email to