📄 index.jsp
字号:
<%@ page contentType="text/html; charset=gb2312" language="java"
import="java.sql.*" errorPage=""%>
<!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>index</title>
<style type="text/css">
<!--
body {
background-color: #93A070;
background-image: url();
margin-left: 150px;
margin-top: 100px;
margin-right: 150px;
margin-bottom: 100px;
}
#Layer1 {
position:absolute;
width:200px;
height:180px;
z-index:1;
left: 155px;
top: 271px;
}
#Layer2 {
position:absolute;
width:200px;
height:256px;
z-index:1;
left: 0px;
top: 22px;
}
-->
</style>
<link href="css.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
.STYLE4 {font-size: 16px}
-->
</style>
</head>
<body>
<jsp:useBean id="myCon" scope="page" class="MyWeb.db.DBManager" />
<%
String sql = null;
java.sql.ResultSet rs = null;
sql = "select * from administrator";
rs = myCon.executeQuery(sql);
%>
<table width="900" height="450" border="0" background="pic/copy.jpg">
<tr>
<td>
<p>
</p>
<p>
</p>
<p>
</p>
<p>
</p>
<p>
</p>
<form id="form1" name="form1" method="post" action="logon.jsp">
<table width="220" height="162" border="0">
<tr>
<td height="40" valign="top">
<span class="STYLE4">用户名称</span>
<select name="userid">
<option>
admin
</option>
</select>
</td>
</tr>
<tr>
<td height="45" valign="middle">
<span class="STYLE4">用户密码</span>
<input name="password" type="password" value="" size="9" />
</td>
</tr>
<tr>
<td height="55" align="left" valign="middle">
<label>
<input type="submit" name="Submit" value="确定" />
</label>
<label>
<input type="button" name="Submit2" value="取消" />
</label>
</td>
</tr>
</table>
<center>
<%
String error = request.getParameter("error");
if (error == null) {
} else {
if (error.equals("2")) {
out.println("请认真填写用户信息!");
} else {
if (error.equals("1")) {
out.println("用户或者密码错误请检查!");
}
}
}
%>
</center>
</form>
</td>
</tr>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -