1
zer0fill
*RESOLVED* Specific censor replacement (making include() in "module.textsanitizer.php")
  • 2004/7/2 7:19

  • zer0fill

  • Not too shy to talk

  • Posts: 137

  • Since: 2003/12/2


I'm trying to make my customized text replacement in an external file so there is only need to edit 1 line of code, the include() statement in the list of $patterns/$replacements but can't seem to get it working.

"module.textsanitizer.php"
$patterns[] = "/[u](.*)[/u]/sU";
$replacements[] = '<u>\1</u>';
$patterns[] = "/[d](.*)[/d]/sU";
$replacements[] = '<del>\1</del>';
include_once(
'custom_text_replacement.php');
...


"custom_text_replacement.php"
<?php
$patterns
[] = "/bub/isU";
$replacements[] = 'yo[u]';
?>


If I move the contents of custom_text_replacement into the include_once() line, it'll work fine.

my file was mis-spelled

Login

Who's Online

254 user(s) are online (158 user(s) are browsing Support Forums)


Members: 0


Guests: 254


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits