What are the options for searching via regex and replacing. searchAndReplace does not work.
I am looking to scrub all occurance of sensitive data that matches a simple regex /\d{3}-\d{2}-\d{4}/
🏷️ Limited Offer: 25% OFF 🏷️
First 100 purchases only — Special discount!
Use this coupon on checkout: PHPDXPJ_D1SC1N5T
Get it nowWhat are the options for searching via regex and replacing. searchAndReplace does not work.
I am looking to scrub all occurance of sensitive data that matches a simple regex /\d{3}-\d{2}-\d{4}/
Hello,
searchAndReplace doesn't support searching regular expressions. In addition to the template methods, phpdocx includes DOCXPath to use XPath, but there's no method to do replacements using regular expressions. We have opened a task to add support in a future release of phpdocx.
Regards.