📄 mainframe.jsp
字号:
<%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" errorPage="" %>
<%@include file="sql2005_book.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
</head>
<%
request.setCharacterEncoding("GBK");
String s = request.getParameter("status");
String username1 = request.getParameter("username");
String password1 = request.getParameter("password");
String sql = "{call checkStatus(?,?)}";
cstmt=conn.prepareCall(sql);
cstmt.setString(1,username1);
cstmt.setString(2,password1);
rs = cstmt.executeQuery();
if(s.equals("1")&&(username1.equals(user))&&(password1.equals(password)))
{response.sendRedirect("guanlizhe.htm");}
else{out.println("<p align=center>错误</p>");}
if(s.equals("2")&&(rs.next()))
{
session.putValue("Uname",username1);
%>
<jsp:forward page = "yonghuzhujiemian.jsp?action=view"/>
<%
}
else if(s.equals("3"))
{response.sendRedirect("youkezhujiemian.htm");}
rs.close();
cstmt.close();
conn.close();
%>
<body>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -