Changeset 1288 for devel/lms/join.php
- Timestamp:
- 11/12/07 23:52:49 (1 year ago)
- Files:
-
- devel/lms/join.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
devel/lms/join.php
r659 r1288 45 45 if ($mode == 'join') { 46 46 // validate 47 if (! preg_match("/^[A-Za-z0-9]{3,12}$/",$u->username)) {47 if (!validate_username($u->username)) { 48 48 $messages[] = __gettext("Error! Your username must contain letters and numbers only, cannot be blank, and must be between 3 and 12 characters in length."); 49 } 50 51 if (record_exists('users','username',strtolower($u->username))) { 49 } elseif (!username_is_available(strtolower($u->username))) { 52 50 $messages[] = __gettext("The username '$username' is already taken by another user. You will need to pick a different one."); 53 51 } 54 52 55 if ( $u->password1 != $u->password2 || strlen($u->password1) < 6 || strlen($u->password2) > 16) {53 if (!validate_password($u->password1, $u->password2)) { 56 54 $messages[] = __gettext("Error! Invalid password. Your passwords must match and be between 6 and 16 characters in length."); 57 55 }
