forked from savetheinternet/Tinyboard
-
Notifications
You must be signed in to change notification settings - Fork 197
word_filters
Fredrick Brennan edited this page Apr 18, 2019
·
1 revision
A wordfilter (sometimes referred to as just a “filter” or “censor”) automatically scans users’ posts as they are submitted and changes or censors particular words or phrases.
$config['wordfilters'][] = array('cat', 'dog');
Using Perl Compatible Regular Expressions, you can match more words or phrases, even if they aren’t exact. To use regular expression wordfilters, you must include ‘true’ as the third element in the array. The following example changes both “cat” and “car” to “dog”.
$config['wordfilters'][] = array('/ca[rt]/', 'dog', true);