Forum


Replies: 3   Views: 3449
Unescaped regex
Topic closed:
Please note this is an old forum thread. Information in this post may be out-to-date and/or erroneous.
Every phpdocx version includes new features and improvements. Previously unsupported features may have been added to newer releases, or past issues may have been corrected.
We encourage you to download the current phpdocx version and check the Documentation available.

Posted by metricbpo  · 11-10-2013 - 22:09

Warning:  preg_replace(): Unknown modifier '/' in /usr/local/src/phpdocx_trial/classes/AutoLoader.inc(29) : eval()'d code on line 58

Stack trace:

  1. {main}() /domain/dev.ddesk/skiprm/edit.php:0

  2. preg_replace("/\$NOTE_DATE_d/m/Y\$/", "24/09/2013", "<?xml versio...



As $ is already escape, there are other possible variable characters that need escaping. The variable name contains / as NOTE_DATE_(.*) is being pumped into date() dynamically.