$.ajax({ url:"${pageContext.request.contextPath}/login/checkLogin", data:{"username":username, "password":password}, type:"post", success:function(msg){ if(msg== "success"){ alert("成功了"); window.location = "${pageContext.request.contextPath}/index.jsp"; }else{ alert("出错了"); } }
ajax成功后,返回index界面
最新推荐文章于 2024-05-18 16:42:38 发布