Forum Discussion

alchemiz's avatar
alchemiz
Contributor III
11 months ago
Solved

String replace method where pattern is dynamic

Hi SMEs,

Quick question, is there a way to set the regex pattern in replace method dynamically?

Example:

 

Thanks

  • All good, by putting eval($pattern) will accept the regex pattern.

     

1 Reply

  • All good, by putting eval($pattern) will accept the regex pattern.