10-20-2008, 02:43 PM
|
#6 (permalink)
|
|
Super Moderator
Join Date: Sep 2007
Location: Near you.
Posts: 791
Thanks: 241
|
i tried this but it wont work ? should i maybe do a check if the preg_match is valid by turning it into a var, and then running a check or how should i do it :S
Thank you!
PHP Code:
if(preg_match('/^([a-zA-Z0-9])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-]+)+/', $email)) { $query=( "INSERT INTO user (id, username,password,email,rank,referral,joined,ip) VALUES ('$id','$username',password('$password'),'$email','Normal','$referral',NOW(),'$ip')"); mysql_query($query) or die(mysql_error()); } else { echo 'Not a valid email!'; } else { echo 'Your account was made!'; } } } }
|
|
|
|