July 23rd, 2002, 02:21 PM
complex URL's in xsl:attribute
I try to create the following using XSL:
But I either get an error because of ampersands and equal signs or a lot of < &amp; when I try the following:
Does anyone know a good solution?
<xsl:value-of select="PHP_SELF" />?<![CDATA
[action=get_record&record=product&id=]]><xsl:value-of select="ID" /></xsl:attribute>
July 28th, 2002, 02:03 AM
First of all, your source:
Will generate errors in any decent XML parser - you can't have unadorned ampersands in your XML files - this line should read:
You'll also need to replace the & with the entitity replacement value in your XSLT. Don't worry, the browser will be able to read it.
Don't forget the closing tag to </xsl:element> too.