[xsl] XSLT2 Character Maps

Subject: [xsl] XSLT2 Character Maps
From: "Christian Roth" <roth@xxxxxxxxxxxxxx>
Date: Sat, 24 Jul 2004 13:54:05 +0200

I've had a look at XSLT 2's character maps feature. In the tool I am
working on (upCast from infinity-loop), we have that very concept
implemented now for several releases and added some convenience options
(like the ability to easily define a range of Unicode positions that
should be output as numerical decimal/hexadecimal entities) - but that's
not the issue here.

The point is that we resp. some of our users also use character maps to
create (mainly empty) elements in the output. For example a line in our
maps like


creates a linebreak element in the output for every instance of Unicode
character &#x2028;. The problem that arises for us is attribute values:
If these contain a 0x2028 character, they get malformed:

<element attr="a&#x2028;b">
<element attr="a<linebreak/>b">,

which is not valid XML.

Current Thread