XML Script logo
Filtering Strings
Code
Replace e with u: # filter("Hello.", "e", "u") #
Replace g at the beginning of the string with G: # filter("greetings!", "^g", "G") #
The regular expression here is \. but we must escape the \: # filter("Hello.", "\\.", "!") #
Output
Replace e with u: Hullo.
Replace g at the beginning of the string with G: Greetings!
The regular expression here is \. but we must escape the \: Hello!
Ref

x.4801

XML Script homepage | Documentation home | XML Script docs | Command list | Function list | X-Tract docs

X-Stream, X-Tract and XML Script are trade marks of DecisionSoft Limited
© Copyright 1998-2000 DecisionSoft Limited