This shows you the differences between two versions of the page.
Previous revision | |||
— | reference:spamrules_statement_replace [2018/11/14 10:45] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ======Spam Filter Rules: Replace====== | ||
+ | ^Statement | ||
+ | ^Version | ||
+ | ^Purpose | ||
+ | |||
+ | **Replace** statements require a variable name, a search value and a replacement string, in the format | ||
+ | Replace < | ||
+ | |||
+ | * The search expression can be a regular expression if desired. | ||
+ | * The **Replace** statement will replace all occurrences of the search expression, not just the first occurrence. | ||
+ | |||
+ | =====Example===== | ||
+ | The following code will change the value of ' | ||
+ | < | ||
+ | ${myvar} = " | ||
+ | |||
+ | Replace myvar " | ||
+ | |||
+ | # The new value of ${myvar} is " | ||
+ | </ | ||