From: moodler Date: Mon, 30 Dec 2002 15:38:10 +0000 (+0000) Subject: Allow "." and "-" in usernames. X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=86d64493068b05958cbb9732095e26b554ee8c88;p=moodle.git Allow "." and "-" in usernames. --- diff --git a/user/edit.php b/user/edit.php index 5744dd0f68..011bc2cdc5 100644 --- a/user/edit.php +++ b/user/edit.php @@ -166,7 +166,7 @@ function find_form_errors(&$user, &$usernew, &$err) { $err["username"] = get_string("usernameexists"); } else { - $string = eregi_replace("[^([:alnum:])]", "", $user->username); + $string = eregi_replace("[^(-\.[:alnum:])]", "", $user->username); if (strcmp($user->username, $string)) $err["username"] = get_string("alphanumerical"); }