|
$login =(trim($_POST['login'])); // login name
$passwd =(trim($_POST['passwd'])); // login passord
/**************************************************************************/
//Validating UserName and Password
$valid = 1;
if(ereg(" ",$login)) $valid = 0;
if(ereg(" ",$passwd)) $valid = 0;
if($valid == 0)
{
header("Location:index.php?Err=ad1002");
exit;
}
/********************checking login***************************************/
$sql ="SELECT * FROM partners_admin where pma_login='$login'='$login' AND pma_password='$passwd'";
$result =mysql_query($sql);
echo mysql_error();
if(mysql_num_rows($result)) //login sussess ful
------------------------------
这到底是怎么验证登录的
这个验证和sql没关系吧 |
|