RE: [xsl] Help Me Do Something Bad

Subject: RE: [xsl] Help Me Do Something Bad
From: "kent" <kent@xxxxxxxxxxxxxxxxx>
Date: Thu, 7 Apr 2005 21:14:22 +0200
I thought so, but I disabling in the wrong place, silly me, thanks again
everyone for the meaty and quick responses.

-----Original Message-----
From: Michael Kay [mailto:mike@xxxxxxxxxxxx] 
Sent: Thursday, April 07, 2005 8:55 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: RE: [xsl] Help Me Do Something Bad

Think of it this way: parsing the data turns angle brackets into nodes, and
&lt; into angle brackets. You can think of this as unescaping. Serializing
the data turns nodes into angle brackets, and angle brackets into &lt; You
can think of this as escaping. In your transformation you want to turn &lt;
into angle brackets which means you need to unescape once more often than
you escape. This is what disable-output-escaping does.

Michael Kay
http://www.saxonica.com/
 

> -----Original Message-----
> From: kent [mailto:kent@xxxxxxxxxxxxxxxxx] 
> Sent: 07 April 2005 19:16
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject: [xsl] Help Me Do Something Bad
> 
> I know escaped content in xml is bad, but I've got some and I wanna do
> something with it. Pleas help?!
> 
> I have markup like this:
> <description>Platform Computing's &lt;a
> href="http://www.platform.com/newsevents/pressreleases/preleas
> e.asp?id=82"
> &gt; announcement &lt;/a&gt; However, &lt;a
> href="http://www.gridsystems.com"; &gt;...</description>
> 
> I want to transform it to html. Like this,
> 
> <xsl:for-each select="description" >
>         <xsl:apply-templates />
> </xsl:for-each>
> 
> I do not believe disable-output-escaping is the solution cuz 
> it has already
> been disabled. So I am stumped how do I de-escape this? Any help would
> really be appreciated.
> 
> Thanks
> 
> kent

Current Thread