PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
if (!get_magic_quotes_gpc()) {
$username = addslashes($username); }
$name_check = mysql_query("SELECT Username FROM users WHERE Username=$username");
if (DB::isError($name_check)) {
return($name_check->getMessage());
}
$name_checkk = $name_check->numRows();
if ($name_checkk != 0) {
return('Sorry, the username: $username is already taken, please pick another one.'); $errors++;}
BTW, you also have a spelling error(Don't know if it's intended).
On your third if statement, it says if ($name_checkk... it has 2 k's. Again, don't know if it's intended, but you might wanna fix that if it's not intended.