This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Ampersand in url
- To: <xsl-list at lists dot mulberrytech dot com>
- Subject: [xsl] Ampersand in url
- From: Jeroen Janssen <jeroen at laika dot nl>
- Date: Thu, 13 Sep 2001 13:04:40 +0200
- Reply-To: xsl-list at lists dot mulberrytech dot com
I'm trying to construct a url in my xsl, the url contains an ampersand and I
can't get it to output it as & instead of &
I want this:
action="storecountry.asp?id=1&mode=edit"
But I get this:
action="storecountry.asp?id=1&mode=edit"
I have tried every possible combination of CDATA and enable-output-escaping,
but to no avail.
I have tried this:
<form method="post">
<xsl:attribute name="action">storecountry.asp?id=<xsl:value-of
select="country/@id"/><xsl:text
disable-output-escaping="yes"><![CDATA[&]]>mode=</xsl:text><xsl:value-of
select="$mode"/>
</xsl:attribute>
This:
<form method="post">
<xsl:attribute name="action">storecountry.asp?id=<xsl:value-of
select="country/@id"/><![CDATA[&]]>mode=<xsl:value-of select="$mode"/>
</xsl:attribute>
And this:
<form method="post">
<xsl:attribute name="action">storecountry.asp?id=<xsl:value-of
select="country/@id"/><xsl:text
disable-output-escaping="yes">&mode=</xsl:text><xsl:value-of
select="$mode"/>
</xsl:attribute>
And a couple more variations... but the result is always the same: & in
the result.
I'm using msxml 3 btw.
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list