📄 loginxszs.jsp
字号:
<%@ page contentType="text/html; charset=gb2312" %>
<%@ page language="java" import="java.sql.*" %>
<%
int counter=0;
Cookie cookies[]=request.getCookies();
if(cookies!=null){
for(int i=0;i<cookies.length;i++){
if(cookies[i].getName().equals("counter"))
counter=Integer.parseInt(cookies[i].getValue());
}
}
%>
<html>
<head>
<title>学生宿舍查询</title>
<!--验证用户名跟密码-->
<script language="JavaScript">
<!--
function validateLogin(){
var strusername=form1.textfield1.value;
var strpassword=form1.textfield2.value;
if(strusername==""){
alert("请输入姓名!");
return false;
}
if(strpassword==""){
alert("请输入学号!");
return false;
}
if(isNaN(strpassword))return (strpassword=''),alert('学号只能输入数字!'),false;
}
-->
</script>
<style type="text/css">
<!--
table {
font-family: "宋体";
font-size: 14px;
color: #000000;
}
.unnamed1 {
border-bottom-width: 1px;
border-bottom-style: dashed;
border-bottom-color: #333333;
border-top-width: 1px;
border-top-style: dashed;
border-top-color: #000099;
}
.unnamed2 {
border-left-width: thin;
border-left-style: dashed;
border-left-color: #000000;
}
.style3 {
font-size: 18px;
font-weight: bold;
}
.style5 {
color: #FF0000;
font-size: 18px;
}
-->
</style>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" background="images/background.gif">
<SCRIPT LANGUAGE=JavaScript>
<!-- Begin
if (window.print) {
document.write('<form>'
+ '<input type=button name=print value=打印 '
+ 'onClick=javascript:window.print()></form>');
}
// End -->
</script>
<!-- ImageReady Slices (glry) -->
<table id="__01" width="680" height="425" border="0" cellpadding="0" cellspacing="0" align="center" background="images/glry_11.gif">
<!--DWLayoutTable-->
<tr>
<td height="55" colspan="6">
<img src="images/glry_01.gif" width="680" height="55" alt=""></td>
</tr>
<tr>
<td height="46" colspan="6">
<img src="images/glry_02.gif" width="680" height="46" alt=""></td>
</tr>
<tr>
<td height="41" colspan="6">
<img src="images/glry_03.gif" width="680" height="41" alt=""></td>
</tr>
<tr>
<td colspan="6" background="images/glry_04.gif" height="20" alt="">
<font color="#FF0000" size="2"><jsp:include page="time.htm"/>
<%
if(counter==0){
//if(session.getAttribute("counter1") == null){
out.print("欢迎首次光临!");
}
else{
out.print("今天您已经光临了"+counter+"次!");
//out.print("您已经光临了"+session.getAttribute("counter1")+"次!");
}
%></font></td>
</tr>
<tr>
<td width="115" height="19">
<a href="gongyu.jsp"><img src="images/glry_05.gif" alt="" width="115" height="19" border="0"></a></td>
<td width="113">
<a href="ry.jsp"><img src="images/glry_06.gif" alt="" width="113" height="19" border="0"></a></td>
<td width="112">
<a href="xszs.jsp"><img src="images/glry_07.gif" alt="" width="112" height="19" border="0"></a></td>
<td width="113">
<a href="wh.jsp"><img src="images/glry_08.gif" alt="" width="113" height="19" border="0"></a></td>
<td width="113">
<a href="lx.jsp"><img src="images/glry_09.gif" alt="" width="113" height="19" border="0"></a></td>
<td width="114">
<a href="hd.jsp"><img src="images/glry_10.gif" alt="" width="114" height="19" border="0"></a></td>
</tr>
<tr>
<td height="20" colspan="6" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" class="unnamed1">
<!--DWLayoutTable-->
<tr>
<td width="556" height="20" valign="top"><a href="gongyu.jsp">首页</a>>>学生宿舍查询 </td>
<td width="124" valign="top"><a href="zhexiao.jsp">注销<%=session.getAttribute("username")%></a></td>
</tr>
</table></td>
</tr>
<tr>
<td height="172" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td width="115" height="24" valign="top"><div align="center" class="style3">学生登录</div></td>
</tr>
<tr>
<td height="147" valign="top">
<form name="form1" method="post" action="checkxszs.jsp" onSubmit="return validateLogin();">
<p> 姓名:
<input name="textfield1" type="text" size="15">
</p>
<p> 学号:
<input name="textfield2" type="text" size="15">
</p>
<p>
<input type="submit" name="Submit" value="提交">
<input type="reset" name="Submit2" value="重置">
</p>
</form></td>
</tr>
</table></td>
<td colspan="5" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" class="unnamed2">
<!--DWLayoutTable-->
<tr>
<td width="565" height="172" valign="top">
<p align="center" class="style5"> </p>
<p align="center" class="style5">你还没登录! </p>
<p align="center" class="style5">请你登录后再查询!</p>
</div></td>
</tr>
</table></td>
</tr>
<tr>
<td height="48" colspan="6">
<img src="images/glry_12.gif" width="680" height="48" alt=""></td>
</tr>
</table>
<!-- End ImageReady Slices -->
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -