philguillard wrote:
I've found a way, maybe this could help for others ...

<xsl:variable name="apos" select='"&apos;&apos;"'/>

Only one &apos; should be necessary there:
   <xsl:variable name="apos" select='"&apos;&apos;"'/>
Another way to do it is
   <xsl:variable name="apos">'</xsl:variable>

Lars

then anywhere in the XSL template :

{translate($foo,$apos, '`')}



Phil

philguillard wrote:
Hi all,

Hum.. I want to escape the apostrophe (') in XSL
Example : foo value is "I'm askin' to cocoon's mailinglist"

None of these tries are correct :

<xsl:value-of select="translate($foo,''', '')"/>
<xsl:value-of select="translate($foo,'&apos;', '')"/>
<xsl:value-of select="translate($foo,&apos;, '')"/>

Then i tried to define $apos as a variable to be able to use the transfrom function, but the same problem arizes when i declare it :

<xsl:variable name="apos" select="'''" />
or
<xsl:variable name="apos" select="'" />


Regards,

Phil


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]