-2

I am using the xslt for transformation but from input 240 characters receiving in one element ,In that element different special characters receiving(eg :---> %,?,/,-,_,@,!,$,^) .

I need to replace the those characters.

It is possible in XSLT 1.0.If it is possible can you please give me the code with examples?.Thanks

Eg:

<remark> whfwlknf234@skl$ck?nvwkld^fnwlfn </remark>
michael.hor257k
  • 113,275
  • 6
  • 33
  • 51
vinod
  • 1
  • 1
  • 1
    Possible duplicate of [Replace special characters in XSLT](http://stackoverflow.com/questions/5084065/replace-special-characters-in-xslt) – Jongware Oct 02 '15 at 14:43

1 Answers1

1

It is possible in XSLT 1.0

Yes, it is possible. Use the translate() function to replace them with ... oh, you didn't say with what.

michael.hor257k
  • 113,275
  • 6
  • 33
  • 51
  • My input xml : wbhdcb?uish@dc!wdh*uwh Expecting out Put:---> wbhdcb%?%uish%@%dc'!'wdh'*'uwh If we will use translate just only one character it will be replaced but in this case instead of ? need to translate to %?% . If it is possible can u please explain.Thanks. – vinod Oct 03 '15 at 08:13
  • @vinod Please don't post code in comments - edit your question instead. – michael.hor257k Oct 03 '15 at 09:01