Is it possable to disable word filters for 1 board? ???
I don't think you can as it is, but you could mod it to work that way, I guess.
I want to setup a board where members can "vent" about something. I want no word filters on that board. btw, this was requested by members. :D
<edit file>
Sources/Load.php
</edit file>
<search for>
// Replace all vulgar words with respective proper words. (substring or whole words..)
function &censorText(&$text)
{
global $modSettings, $options, $settings;
static $censor_vulgar = null, $censor_proper;
</search for>
<add after>
// Uncensored board.
global $board;
if (!empty($board) && $board == 1)
return $text;
</add after>
Replace the 1 with the ID of the board you want uncensored. If you want to forgive more than one board, you'd change that line to this:
if (!empty($board) && ($board == 1 || $board == 2))
That'd not censor boards 1 and 2, you can add more. Again, you use the correct board IDs, this is just an example.
Hope it helps. ;)
Sweet, I'll give that a shot
Zitat von: quake101 in Oktober 08, 2004, 06:54:15 NACHMITTAGS
Sweet, I'll give that a shot
Cool. Let me know if it worked for you.
Note: This could probably go in Tips and Tricks?
Hey, That worked great! Thank!!!!! ;D
Anguz,
I got this to work beautifully on my site (it's something I've been trying to figure out for some time), but can you explain to me WHY it works? I'd been experimenting with putting the entire CensorText() function in an if statement that said
if $board != 14 {censortext}
but $board was not being recognized. How come when you added
// Uncensored board.
global $board;
if (!empty($board) && $board == 1)
return $text;
$board is suddenly recognized by the code? Did the simple fact of declaring it make it visible, whereas not declaring it makes it invisible?
Just curious - and thanks VERY MUCH for the code snippet.
Zitat von: Stumpy in August 28, 2007, 05:06:26 NACHMITTAGS
Anguz,
I got this to work beautifully on my site (it's something I've been trying to figure out for some time), but can you explain to me WHY it works? I'd been experimenting with putting the entire CensorText() function in an if statement that said
if $board != 14 {censortext}
but $board was not being recognized. How come when you added
// Uncensored board.
global $board;
if (!empty($board) && $board == 1)
return $text;
$board is suddenly recognized by the code? Did the simple fact of declaring it make it visible, whereas not declaring it makes it invisible?
Just curious - and thanks VERY MUCH for the code snippet.
It's because it was defined on "global $board;"; line 2.
thanks, this is a great future!!
I even wrote a mod for this for SMF 2.0 - Uncensored Boards (http://custom.simplemachines.org/mods/index.php?mod=2176)
This should be moved to the Now Available board.
btw Nice mod Arantor
I'm not moving this to Now Available since this thread covers it for 1.1, my mod is 2.0 only.
Zitat von: Arantor in Oktober 31, 2009, 01:15:08 NACHMITTAGS
I even wrote a mod for this for SMF 2.0 - Uncensored Boards (http://custom.simplemachines.org/mods/index.php?mod=2176)
An excellent mod, Arantor. I love it.
Note that I don't maintain it any longer.