![]() |
Disable swear filter for certain forums?
Does anyone think it would be possible to create a hack so as to disable the swear filter on just a few forums? By and large, we don't allow swearing at my board, but I would like to enable it for just a couple of forums. Is it possible? If so, could someone do this for me? :classic:
|
in newthread.php, newreply.php, editpost.php find:
PHP Code:
PHP Code:
|
Awesome! Thanks. :)
Would these settings carry over to sub-forums, or would I need to add each forumid? |
What if you wanted to have more than one forum included? And if it were just one forum, would x and y be the same number?
|
Quote:
Quote:
if ($foruminfo[forumid]!=X) 2 forums: if ($foruminfo[forumid]!=X AND $foruminfo[forumid]!=Y) 3 forums: if ($foruminfo[forumid]!=X AND $foruminfo[forumid]!=Y AND $foruminfo[forumid]!=Z) 4 Forums: if ($foruminfo[forumid]!=X AND $foruminfo[forumid]!=Y AND $foruminfo[forumid]!=Z AND $foruminfo[forumid]!=W) etc. |
This modification works for the subject but not the message body. The swear filter is not implemented for the message subject (meaning the subject can contain words in the censoer list in the thread title) but the body text still gets censored. There is a missing piece here somewhere.
|
Quote:
here is the missing part: edit functions.php, find: Quote:
Quote:
Quote:
Quote:
|
Thank you, that works correctly. :)
|
Is there some kind of evaluation I can add to that section in functions.php that could test if it was a private message? As it is this modification allows censored text in Private Message body text but not titles.
|
yep.. put a variable like "$my_priv_variable=1;" in private message related scripts right before it calls the function bbcodeparse2 and use the same method: Add the variable to the global line of the function and return result accordingly like:
PHP Code:
PHP Code:
|
Thanks for all your help. :)
I will test this all soon and let you know how it works for us. |
I tested that and it didn't work out, but I found something that did since you helped me find the code in private.php. :)
I heavily modified all of this so it would be a setting controllable from the admin CP when editing or adding forums, and so there were no bugs in post or topic titles when editing replying or posting a new thread, as well as applying it to the edit reason hack I have on our forums from Firefly's assortment of hacks available. It all works great and I have you to thank Logician, because you led this lost hacker to all the right places. Thanks! :) |
All times are GMT. The time now is 02:46 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|