Avatar

Allowed (?) word (Bugs)

by Alfie ⌂, Vienna, Austria, Monday, May 05, 2008, 22:34 (5806 days ago) @ Per Bylund

I've tested this enough to know that it is indeed the word socialist. Anybody heard about this problem before? It seems like a very strange word to censor in the source code... :-P

Dear Per,

very strange! :confused:
I'm running v1.7.5 in English, and got no problems with any of 'socialist, socialists, socialism'.
I added 'socialis' to my banlist -> posting was refused -> removed it -> posting was possible.

There is just one section of the source (>1.6) checking entries for banned words in the database, namely a couple of lines in 'posting.php':

// check for not accepted words:
$result=mysql_query("SELECT list FROM ".$db_settings['banlists_table']." WHERE name = 'words' LIMIT 1", $connid);
if(!$result) die($lang['db_error']);
$data = mysql_fetch_array($result);
mysql_free_result($result);
if(trim($data['list']) != '')
 {
  $not_accepted_words = explode(',',trim($data['list']));
  foreach($not_accepted_words as $not_accepted_word)
   {
    if($not_accepted_word!='' && (preg_match("/".$not_accepted_word."/i",$name) || preg_match("/".$not_accepted_word."/i",$text) || preg_match("/".$not_accepted_word."/i",$subject) || preg_match("/".$not_accepted_word."/i",$email) || preg_match("/".$not_accepted_word."/i",$hp) || preg_match("/".$not_accepted_word."/i",$place)))
     {
      $errors[] = $lang['error_not_accepted_word'];
      break;
     }
   }
 }


The code is identical in all versions within 1.6.2 and 1.7.5; so I don't see why you are facing this problem. Maybe you should check the table 'forum_banlists' in your database...

--
Cheers,
Alfie (Helmut Schütz)
BEBA-Forum (v1.8β)

locked
7839 views

Complete thread:

 RSS Feed of thread