RE: [xsl] : Escaping '&' in an HTML link.

Subject: RE: [xsl] : Escaping '&' in an HTML link.
From: Ram Gande <Ram.Gande@xxxxxxxxxx>
Date: Mon, 30 Jul 2001 14:58:42 -0700
You can do either by using "CDATA" or "&amp;".
Both worked for me.

-Hope it helps.

-----Original Message-----
From: Aparna Joshi [mailto:aparna.joshi@xxxxxxxxxx]
Sent: Monday, July 30, 2001 2:03 PM
To: 'xsl-list@xxxxxxxxxxxxxxxxxxxxxx'
Subject: [xsl] : Escaping '&' in an HTML link.


Here is my stylesheet (basic structure):

<xsl:stylesheet xmlns:xsl="";
<xsl:param name="address">index.jsp</xsl:param>
<xsl:output method="html" indent="yes" />  

<xsl:template match="AAA">

       <body >
		<form method="POST" name="index" action="{$address}">
                Your request: <input type="text" name="query"
                          <input type="submit" name="go" value="GO"></input>
				<xsl:attribute name="href">
select="translate(normalize-space(groupName),' ','+')"/>
       </body >

But this link fails when it encounters a value with "&" in it e.g.
Star&Bucks fails because of the '&' in between.
Is there any to escape the '&' so that the URL is completely and properly
I tried "disable-output-escaping" but it didnot seem to work.

Thanks in anticipation for any help provided.


 XSL-List info and archive:

 XSL-List info and archive:

Current Thread