<?php
include("../../conn/conn.php");
$select=mysql_query("select*from tb_user name='".$_POST['name']."' and pwd='".$_POST['pwd']."'",$conn);
echo $select;
if(isset($_POST['submit']) and $_POST['name']!=null and $_POST['pwd']!=null){
if(mysql_num_rows($select)==1){
echo "<script>alert('登录成功!');window.location.href='index.php'</script>";
}else{
echo "<script>alert('登录失败!');window.location.href='index.php'</script>";}
}
?>
那位高手帮忙看看啊,非常感谢!