⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 exchange.jsp

📁 利用java编写的一个学生宿舍管理系统
💻 JSP
字号:
<%@ page contentType="text/html; charset=gb2312" language="java"  %>
<%
if(session.getAttribute("admin")==null)
     out.print("<script>alert('请先登录!');window.location.href='login.htm'</script>");
%>
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>调房登记</title>
<link href="css/mycss.css" rel="stylesheet" type="text/css">
<SCRIPT Language="JavaScript">
<!--
//下面的副程序将执行资料检查
function datacheck()
{
   //下面的if判断语句将检查是否输入帐号资料
   if(form.studentid.value=="")
   {
      //显示错误信息
      alert("请输入学号!");
      //将光标移至学号输入栏
      document.form.elements(0).focus();
    }else{
       if(form.ydonghao.value=="")
       {
         alert("请输入调出楼号!");
         document.form.elements(1).focus();
       }else{
	      if(form.yhouseid.value=="")
		  {
			 alert("请输入调出房号!");
			 document.form.elements(2).focus();
		  }else{ 
	         if(form.xdonghao.value=="")
	        {
                alert("请输入调入楼号!");
	            document.form.elements(3).focus();
	        }else{
	            if(form.xhouseid.value=="")
                {
                    alert("请输入调入房号!");
	                document.form.elements(4).focus();
	            }else{
		            if(form.intime.value=="")
		            {
		                alert("请输入调房日期!");
	                    document.form.elements(5).focus();
                    }else{
		                form.submit();//送出表单中的资料
	                }
	             }
			  }
	       }
        }
     }
 }										  
-->
</script>
</head>

<body>
<%@ include file="head.htm" %>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
  
<form name="form" method="post" action="/MyDesign/Exchange">
  <table width="29%" border="1" align="center" bordercolor="#660000" bgcolor="#CCCCCC">
    <tr> 
      <td colspan="2"><div align="center"><font color="#660000"><strong><font size="5">调房登记</font></strong></font></div></td>
    </tr>
    <tr> 
      <td width="40%"><div align="center"><font color="#660000">学号</font></div></td>
      <td width="60%"><font color="#660000"> 
        <input name="studentid" type="text" id="studentid" size="20" maxlength="10">
        </font></td>
    </tr>
    <tr> 
      <td><div align="center"><font color="#660000">调出楼号</font></div></td>
      <td><font color="#660000"> 
        <input name="ydonghao" type="text" id="ydonghao" size="20" maxlength="2">
        </font></td>
    </tr>
    <tr> 
      <td><div align="center"><font color="#660000">调出房号</font></div></td>
      <td><font color="#660000"> 
        <input name="yhouseid" type="text" id="yhouseid" size="20" maxlength="4">
        </font></td>
    </tr>
    <tr> 
      <td><div align="center"><font color="#660000">调入楼号</font></div></td>
      <td><font color="#660000"> 
        <input name="xdonghao" type="text" id="xdonghao" size="20" maxlength="2">
        </font></td>
    </tr>
    <tr> 
      <td><div align="center"><font color="#660000">调入房号</font></div></td>
      <td><font color="#660000"> 
        <input name="xhouseid" type="text" id="xhouseid" size="20" maxlength="4">
        </font></td>
    </tr>
    <tr>
      <td><div align="center"><font color="#660000">调房日期</font></div></td>
      <td><input name="intime" type="text" id="intime" size="20" maxlength="20"></td>
    </tr>
    <tr> 
      <td colspan="2"><div align="center"> <font color="#660000"> 
          <input type="button" name="Submit" value="调换" onClick="datacheck()">
          &nbsp;&nbsp; &nbsp; 
          <input type="reset" name="Submit2" value="重置">
          </font></div></td>
    </tr>
  </table>
  </form>
  <strong></strong></div>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -