• 2020/12/10


    <%@ page language="java" contentType="text/html; charset=UTF-8"
        pageEncoding="UTF-8"%>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>Insert title here</title>
    <style>
        .a{
            margin-top: 20px;
        }
        .b{
            font-size: 20px;
             160px;
            color: white;
            background-color: greenyellow;
        }
    </style>
    </head>
    <body>
    <%
             Object message = request.getAttribute("message");
             if(message!=null && !"".equals(message)){
          
        %>
             <script type="text/javascript">
                  alert("<%=request.getAttribute("message")%>");
             </script>
        <%} %>
    <center>
    
    <h2 style="color: red;">登录</h2>
    <div>
     <form action="Servlet?method=tjudge" method="post" >
     <div class="a">
                    教师工号:<input type="text" id="tid" name="tid" />
                </div>
               <div class="a">
                   教师姓名:<input type="text" id="tname" name="tname" />
                     </div>
                     
             <div class="a">
                    <button type="submit" class="b">提  交<tton>
             </div>
        </center>
    </body>
    
    <%@ page language="java" contentType="text/html; charset=UTF-8"
        pageEncoding="UTF-8"%>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>Insert title here</title>
    <style>
        .a{
            margin-top: 20px;
        }
        .b{
            font-size: 20px;
             160px;
            color: white;
            background-color: greenyellow;
        }
    </style>
    </head>
    <body>
    <center>
    <h2 style="color: red;">教师登录界面</h2>
    <div>
    <a href="kadd.jsp">1.添加课程</a>
    </div>
    <div>
    <div>
    </div>
    <form action="Servlet?method=save" method="post" >
    <button type="submit" >2.修改个人信息<tton>
    </div>
    <div>
    <div>
    </div>
    <a href="sadd.jsp">3.浏览选课学生信息</a>
    </div>
    </center>
        
    </body>
    
    <%@ page language="java" contentType="text/html; charset=UTF-8"
        pageEncoding="UTF-8"%>
        <%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>Insert title here</title>
    <style>
        .a{
            margin-top: 20px;
        }
        .b{
            font-size: 20px;
             160px;
            color: white;
            background-color: greenyellow;
        }
    </style>
    </head>
    <body>
       
        <%
             Object message = request.getAttribute("message");
             if(message!=null && !"".equals(message)){
          
        %>
             <script type="text/javascript">
                  alert("<%=request.getAttribute("message")%>");
             </script>
        <%} %>
       
        <div align="center">
            <h1 style="color: red;">教师信息修改系统</h1>
             
              <form action="Servlet?method=tgai" method="post" >
         <c:forEach items="${holds}" var="item" varStatus="status">
                <div class="a">
                    教师工号:<input type="text" id="tid" name="tid" value=${item.tid}>
                    <button type="submit" class="a">修改<tton>
                </div>
                <div class="a">
                   教师姓名:<input type="text" id="tname" name="tname"value=${item.tname} >
                   <button type="submit" class="a">修改<tton>
                     </div>
                     
                <div class="a">
                   教师性别:<input type="text" id="tsex" name="tsex" value=${item.tsex}>
                   <button type="submit" class="a">修改<tton>
                     </div>     
                     
              <div class="a">
                   老师所在院校:<input type="text" id="tlocation" name="tlocation" value=${item.tlocation}>
                   <button type="submit" class="a">修改<tton>
                     </div>   
                          
                  <div class="a">
                   职称:<select  name="tzc" value=${item.tzc}>
                   <option value="教授" selected>教授</option> 
     				<option value="副教授">副教授</option> 
    				<option value="讲师">副讲师</option> 
     				<option value="助教">助教</option> 
     				
     				</select><button type="submit" class="a">修改<tton>   
                     </div>     
                
                    
              
                
            </form>
        </div>
         </c:forEach>
    	</body>
        <script type="text/javascript">
            function check() {
            	var tid = document.getElementById("tid");
                var tname = document.getElementById("tname");
                var tsex = document.getElementById("tsex");
            	var tlocation = document.getElementById("tlocation");
                var tzc = document.getElementById("tzc");
                 
                //非空
                if(tid.value == '') {
                    alert('工号有误');
                    houselei.focus();
                    return false;
                }
                else if(tname.value == '') {
                    alert('名字有误');
                    mianji.focus();
                    return false;
                }
                else if(tsex.value == '') {
                    alert('性别有误');
                    housege.focus();
                    return false;
                }
                else if(tlocation.value == '') {
                    alert('所在院校为空');
                    name.focus();
                    return false;
                }
                else if(tzc.value == '') {
                    alert('职称为空');
                    shenfen.focus();
                    return false;
                }
                       
                  else
                {
                	alert('添加成功');
                	}
            }
                </script type="text/javascript">
       
    
    <%@ page language="java" contentType="text/html; charset=UTF-8"
        pageEncoding="UTF-8"%>
        <%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>Insert title here</title>
    <style>
        .a{
            margin-top: 20px;
        }
        .b{
            font-size: 20px;
             160px;
            color: white;
            background-color: greenyellow;
        }
    </style>
    </head>
    <body>
       
        <%
             Object message = request.getAttribute("message");
             if(message!=null && !"".equals(message)){
          
        %>
             <script type="text/javascript">
                  alert("<%=request.getAttribute("message")%>");
             </script>
        <%} %>
       
        <div align="center">
            <h1 style="color: red;">教师信息修改系统</h1>
             
              <form action="Servlet?method=tgai" method="post" >
         <c:forEach items="${holds}" var="item" varStatus="status">
                <div class="a">
                    教师工号:<input type="text" id="tid" name="tid" value=${item.tid}>
                    <button type="submit" class="a">修改<tton>
                </div>
                <div class="a">
                   教师姓名:<input type="text" id="tname" name="tname"value=${item.tname} >
                   <button type="submit" class="a">修改<tton>
                     </div>
                     
                <div class="a">
                   教师性别:<input type="text" id="tsex" name="tsex" value=${item.tsex}>
                   <button type="submit" class="a">修改<tton>
                     </div>     
                     
              <div class="a">
                   老师所在院校:<input type="text" id="tlocation" name="tlocation" value=${item.tlocation}>
                   <button type="submit" class="a">修改<tton>
                     </div>   
                          
                  <div class="a">
                   职称:<select  name="tzc" value=${item.tzc}>
                   <option value="教授" selected>教授</option> 
     				<option value="副教授">副教授</option> 
    				<option value="讲师">副讲师</option> 
     				<option value="助教">助教</option> 
     				
     				</select><button type="submit" class="a">修改<tton>   
                     </div>     
                
                    
              
                
            </form>
        </div>
         </c:forEach>
    	</body>
    
  • 相关阅读:
    spring的常用配置
    aop切入点表达式
    代理模式
    hibernate的常用配置
    正则表达式
    Java配置
    性能提升
    创建vue3 项目
    manjaro
    单调队列
  • 原文地址:https://www.cnblogs.com/qiangini/p/14162291.html
Copyright © 2020-2023  润新知