Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
replacer
#4
Hi, I had some problems today with the RePlacer plugin. Basically it just replaced the text with empty strings. It's probably my PHP environment, but it worked after I changed 4 lines of code. The diff between the original code and my version is below. I think it's also cleaner. Any change the original coder could look at this "patch" and release a newer version?

Code:
$ diff replacer.php replacer.php.original
168c168
<                 $found_replace[] = (string) $data[$match[1]]->code;
---
>                 $found_replace[] = $data[$match[1]]->code;
175,178c175,178
< #            ob_start();
< #            eval($found_replace[$counter]);
< #            $found_replace[$counter] = ob_get_contents();
< #            ob_end_clean();
---
>             ob_start();
>             eval($found_replace[$counter]);
>             $found_replace[$counter] = ob_get_contents();
>             ob_end_clean();
Reply


Messages In This Thread
replacer - by iaeon - 2010-12-15, 10:47:09
replacer - by RobA - 2010-12-15, 13:22:03
replacer - by iaeon - 2010-12-15, 20:26:58
replacer - by Sodki - 2012-03-05, 07:55:24



Users browsing this thread: 1 Guest(s)