我试图提出一个简单的<代码>IF:
IF $un = mysql_result
die
else
do some code.
这是防止多个用户使用同一名称的过程。
问题在于,它打上了一切,尽管它没有:
if ($result = $UN ) {
$errorMessage = "Name has been Taken";
echo "User name is allready being Used, ";
$_SESSION[ ERRMSG_ARR ] = $errormessage;
echo " Please Go Back and Try Again";
//header("Location: register.php");
exit();
}
else {
echo "not taken -- ";
}