When the password is entered incorrectly, a password error will be displayed instead of not having the account
按键盘手指磨破皮2017-09-09 00:13:38
简单的写下吧 其他的自己改改 $name = $_POST[$name]; //账号 $psw = $_POST[$psw]; //密码 if(!isset($name) || !isset($psw)){ echo "请输入账号和密码"; }else{ //连接数据库进行账号查询,返回结果假设为$name; if(!$name){ echo '账号不正确'; }else { //连接数据库进行密码查询,返回结果假设为$psw; if(!$psw){ echo '密码不正确'; }else { echo '登陆成功'; } } }
IT-小爬虫2017-09-08 14:55:31
First determine whether the account exists, and then determine whether the password is correct based on the existing user.
My rough opinion.