I'm retrieving like this

 <xsl:call-template name="RemoveHtml">
           <xsl:with-param name="String" select="@Person.title"/>

Result looks like this Neill@uxxx.com33Field@uxxx.com

How can i remove the number "33" and replace with space or comma.

Thanks in advance


You need to specify XSLT 1.0 or 2.0: 2.0 makes this kind of thing much easier with the replace() function, which uses regular expressions.

If you're stuck with XSLT 1.0, then try:

normalize-space(translate(xxx, '0123456789', '          '))

which replaces all digits with spaces and then collapses multiple spaces to a single space.

  • Thanks Michael. it did the trick but i had to stick with 1.0 :( – naijacoder Jun 28 '18 at 5:45

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.