1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-01 12:20:44 +02:00

bugfix: disallowed names not tested for properly

This commit is contained in:
mrpete
2007-01-17 13:35:46 +00:00
parent a1422e34ae
commit 1c2d594c29

View File

@@ -11,9 +11,9 @@
| GNU General Public License (http://gnu.org). | GNU General Public License (http://gnu.org).
| |
| $Source: /cvs_backup/e107_0.8/signup.php,v $ | $Source: /cvs_backup/e107_0.8/signup.php,v $
| $Revision: 1.5 $ | $Revision: 1.6 $
| $Date: 2007-01-07 15:59:41 $ | $Date: 2007-01-17 13:35:46 $
| $Author: e107steved $ | $Author: mrpete $
+----------------------------------------------------------------------------+ +----------------------------------------------------------------------------+
*/ */
@@ -402,10 +402,12 @@ if (isset($_POST['register']))
$error = TRUE; $error = TRUE;
} }
global $db_debug;
// Check for disallowed names. // Check for disallowed names.
if(isset($pref['signup_disallow_text'])) if(varsettrue($pref['signup_disallow_text']))
{ {
$tmp = explode(",", $pref['signup_disallow_text']); $tmp = explode(",", $pref['signup_disallow_text']);
if (E107_DEBUG_LEVEL) $db_debug->log('disallowed ('.count($tmp).'), like "'.$tmp[0].'"');
foreach($tmp as $disallow) foreach($tmp as $disallow)
{ {
if( strstr($_POST['name'], $disallow) || strstr($_POST['loginname'], $disallow) ){ if( strstr($_POST['name'], $disallow) || strstr($_POST['loginname'], $disallow) ){