看看一段jsp登录代码

luckboy1017 luckboy1017 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区
while(rs.next())
{ String strstr=rs.getString(1);
out.print(buttonName);
out.print(strstr);
out.print(buttonPass);
if(strstr.equals(buttonPass))
{out.print(buttonPass);
response.sendRedirect("Nteacher.jsp");

}
else{out.print("it is wrong"); }
}
}
catch(SQLException e){System.out.print(e);}


其中butonName 是用户输入的用户名
strstr是数据库里返回的拥护密码
buttonPass 是拥护输入的密码,
已经输出来strstr和buttonpass的值一样
可结果是
apple pple pple it is wrong
怎么就不跳转呀,一夜拉,救救我吧
...全文
评论 8
收藏 已收藏
分享
返回顶部
luckboy1017
Web 开发 81,108 成员 341,721 内容