[xsl] Replace function and apostrophes

Subject: [xsl] Replace function and apostrophes
From: "Andrew Welch" <ajwelch@xxxxxxxxxxxxxxx>
Date: Thu, 17 Feb 2005 14:34:52 -0000
I'm trying to replace all occurances of apostrophes with \' as part of a
variable's select statement:

<xsl:variable name="foo" select="replace(., '&apos;', '\\&apos;'"/>

This fails with "invalid character in expression '\'" - any ideas on how
to do this?

Thanks
andrew

Current Thread