[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

disabling output escaping within an xsl attribute

Subject: disabling output escaping within an xsl attribute
From: joseph_jacob@xxxxxx
Date: Wed, 31 May 2000 01:53:38 -0700
xsl attribute output escaping
I want to generate html output where & (ampersand) characters are not escaped.

Palm VII Web Clipping Applications do not  understand the & character
representation in a URL.
They know how to handle the literal '&' character representation.

Or in other words I want:

http://www.dot.com/service?foo=1&bar=2

and not

http://www.dot.com/service?foo=1&bar=2

I cannot seem to  get disable-output-escaping to work within an xsl:attribute. I
can get it to work for non-attributes. What am I doing wrong ?

Relevant XSL Code fragment
------------------------------------
<*snip*>

<xsl:template match="hedline">
   <xsl:element name="b">
     <xsl:element name="a">
       <xsl:attribute name="href">
         <xsl:value-of disable-output-escaping="yes"
select="string('http://www.dot.com/service?foo=1&amp;bar=2')" />
       </xsl:attribute>
      </xsl:element>
     <xsl:value-of disable-output-escaping="yes"
select="string('&amp;www.dot.com&amp;')"/>
    </xsl:element>
</xsl:template>

<*snip*>

generated the following output:

<b><a href="http://www.dot.com/service?foo=1&amp;bar=2"></a>&www.dot.com&</b>


Note that the disable-output-escaping doesn't seem to work for the href
attribute ( &amp; is retained as &amp;).

Any help would be greatly appreciated.

	
-joe




 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.