Subject: RE: escaping an accented character
From: "Michael Kay" <mhk@xxxxxxxxx>
Date: Tue, 13 Jan 2004 23:28:02 -0000
|
No, it's not wrong.
Presumably the character is in a URI-valued attribute and you are using
the HTML output method. The correct escaping method for such attributes
is to encode the character as a sequence of UTF-8 octets, and then
escape each octet as two hex digits in the form %HH.
Michael Kay
> -----Original Message-----
> From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of
> Peter Hollingsworth
> Sent: 13 January 2004 20:52
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject: escaping an accented character
>
>
> The character à ('a' with a grave accent) appears in a node
> in my XML. When
> I use an XSLT to display the node in an href for link in an
> html page, the
> character gets escaped as %C3%A0, which is completely wrong
> (it should be
> escaped as %E0). Similar problems occur with all accented characters.
>
> Both the XSL and the XML file have encoding="UTF-8" (unicode,
> I believe).
>
> Any suggestions? Thanks.
>
> --Peter
>
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|