Products | Versions |
---|---|
TIBCO IntegrationManager | - |
Not Applicable | - |
Resolution:
Here is an example that shows how to make use of regular expressions in ECMA script task...
//Example to strip html tags
strInput = "<html>kjjljjlj<ggg>jjjllj</ggg>njlkjkljlj</html>";
writeln("Input : " + strInput);
var objRegExp = new RegExp("<(.|\n)+?>");
objRegExp.ignoreCase = true;
objRegExp.global = true;
strOutput = strInput.replace(objRegExp, " ")
writeln("Output : " + strOutput);
If you need more information on how to use regular expressions refer to the following link:
http://home.worldcom.ch/~jmlugrin/fesi/regexpext.html