Added configuration screen for bad words list.

This commit is contained in:
thepurpleblob
2005-07-26 13:06:44 +00:00
parent bf9760c4a8
commit ee780c2d80
2 changed files with 24 additions and 7 deletions
+2 -7
View File
@@ -8,10 +8,5 @@ This is a very simple Text Filter that searches text
being output to the screen, replacing "bad" words
with other words.
To activate this filter, add a line like this to your
config.php:
$CFG->textfilter1 = 'filter/censor/censor.php';
To customise the word list, edit cursor.php.
To customise the word list, use the censor settings page
in the filters administration page.
+22
View File
@@ -0,0 +1,22 @@
<?php
// check the default settings
if (!isset($CFG->filter_censor_badwords)) {
set_config( 'filter_censor_badwords','' );
}
// get strings to use
$txt = new Object;
$txt->badwordslist = get_string( 'badwordslist','admin' );
$txt->badwordsconfig = get_string( 'badwordsconfig','admin' );
?>
<table cellpadding="9" cellspacing="0">
<tr valign="top">
<td align="right"><?php echo $txt->badwordslist; ?></td>
<td><textarea type="text" name="filter_censor_badwords" cols="60" rows="10"><?php echo "$CFG->filter_censor_badwords"; ?></textarea></td>
</tr>
<tr>
<td>&nbsp;</td>
<td><?php echo $txt->badwordsconfig; ?></td>
</tr>
<table>