|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: url encoding of ampersands
> This won't work because there is no ampersand in your *source tree* (which
> was *derived* from your original XML). é in your XML is resolved by
> the XML parser into a single LATIN SMALL E WITH ACUTE character long before
> the XSLT processor sees it. Likewise, your output will be *derived* from
> the result tree you construct, hence the automatic conversion of the
> character in question into é or é by the XSLT processor's
> result tree serializer, just as it would convert an ampersand into &.
Question: if the xslt processor was passed this character from the xml
parser, how is it selected for conversion as opposed to other characters, by
range?
Shouldn't there be a way to be more specific in HTML output mode in regards
to ampersand handling? (using xerces/xalan).
I eventually wrapped all my entities in CDATA so I can later on encode the
ampersands, and did another assignment pass w/ disable-output-escaping to
parse these entities for displaying link content.
Although it works, I don't like the idea of introducing an exception into
the xml itself, which is being handled by non-techies. Only for specific
elements CDATA needs to be used for entities while everywhere else, entities
are handled in a standard manner. I don't think this can be specified in the
DTD.
Thanks for your illuminating comments.
Sivan
> <xsl:variable name="anchor" select="concat(substring-before(.,'é'),
> '%C3%A9',substring-after(.,'é'))"/>
>
> - Mike
> ____________________________________________________________________
> Mike J. Brown, software engineer at My XML/XSL resources:
> webb.net in Denver, Colorado, USA http://skew.org/xml/
>
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
>
>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








