1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-01 04:10:38 +02:00

Bugtracker #5128 - '$' not always detected in profanities

This commit is contained in:
e107steved
2011-02-26 23:07:36 +00:00
parent 098cf5f687
commit c0820771cd

View File

@@ -2,16 +2,15 @@
/* /*
* e107 website system * e107 website system
* *
* Copyright (C) 2008-2009 e107 Inc (e107.org) * Copyright (C) 2008-2011 e107 Inc (e107.org)
* Released under the terms and conditions of the * Released under the terms and conditions of the
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
* *
* *
* *
* $Source: /cvs_backup/e107_0.8/e107_handlers/profanity_filter.php,v $ * $URL$
* $Revision$ * $Revision$
* $Date$ * $Id$
* $Author$
*/ */
if (!defined('e107_INIT')) { exit; } if (!defined('e107_INIT')) { exit; }
@@ -32,6 +31,10 @@ class e_profanityFilter
if($word != "") if($word != "")
{ {
$word_array[] = $word; $word_array[] = $word;
if (strpos($word, '$') !== FALSE)
{
$word_array[] = str_replace('$', '\$', $word); // Special case - '$' may be 'in clear' or as entity
}
} }
} }
if(count($word_array)) if(count($word_array))