I have the string "[test]" in xsl. I need to remove this brackets in the xsl. how can i achieve this in XSL. Please help.
i know this can do it, but how can i remove '[' with below code,
<xsl:call-template name="string-replace-all">
<xsl:with-param name="text" select="$string" />
<xsl:with-param name="replace" select="$replace" />
<xsl:with-param name="by" select="$by" />
</xsl:call-template>
Please help to remove '[' and ']'
Use the translate() function.
Example...
<xsl:call-template name="string-replace-all">
<xsl:with-param name="text" select="$string" />
<xsl:value-of select="translate( $text, '[]', '')" />
</xsl:call-template>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With