The Unicode codepoint x1B is not a valid character in XML 1.0, but it
becomes valid in XML 1.1 provide it is always written as a numerical
character reference, e.g.
& # x 1 B ;
without the spaces.
So you need to do two things:
(a) enable XML 1.1 (details depend on your environment, but as a
minimum, specify version="1.1" in the XML declaration; you may also need
to tell your XSLT processor that you are using XML 1.1)
(b) write the character as a numeric reference, as above.
Michael Kay
Saxonica
On 06/10/2010 6:50 AM, Jimenez, Luis wrote:
Greetings,
how to use the ESC character or 0x1B hex within an XSLT.
I get the following error:
'', hexadecimal value 0x1B, is an invalid character.
The XSL:
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:output method="html" version="1.0" encoding="iso-8859-1" indent="yes"/>
<xsl:strip-space elements="*"/>
<xsl:template match="/">
<xsl:for-each select="/spoolpd/pd">
%-12345X(_at_)PJL ==> LINE WHERE IS THE CHARACTER.
<xsl:copy-of select="."/>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
what would be the solution.
Thanks,
Luis Fdo.
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail:<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--