zoukankan      html  css  js  c++  java
  • 2020 10 29

    学生管理系统,学生查看界面

    <%@ page language="java" contentType="text/ html; charset=UTF-8"
    pageEncoding="UTF-8" import = "java.util.*"%>
    <%@page import="bean.student"%>
    <%@page import="bean.tclass"%>
    <%@page import="bean.teacher"%>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="ISO-8859-1">
    <title>Insert title here</title>
    </head>
    <body>
    <%
    teacher Ateacher=(teacher)session.getAttribute("Ateacher");
    String ID = request.getParameter("ID");
    List<tclass> Atclass=(List<tclass>)session.getAttribute("Atclass");
    List<student> Astudent=(List<student>)session.getAttribute("Astudent");
    out.println(Ateacher.getName());
    session.setAttribute("Ateacher",Ateacher);
    request.setAttribute("Ateacher",Ateacher);
    session.setAttribute("Atclass",Atclass);
    request.setAttribute("Atclass",Atclass);
    session.setAttribute("Astudent",Astudent);
    request.setAttribute("Astudent",Astudent);
    %>
    <form action="Saddc1.jsp" method="post" onsubmit="return chech(this)">
    <table align="center" width="450" border="1">
    <tr>
    <td align="center" colspan="5">
    <h2>浏览课程</h2>
    </td>
    </tr>
    <tr aligh="center">
    <td>学号</td>
    <td>姓名</td>
    <td>性别</td>
    <td>班级</td>
    <td>专业</td>
    </tr>
    <%
    for(tclass p:Atclass){
    if(p.getID().equals(ID))
    {
    String snum[]=p.getStu().split("\+");
    for(String q:snum)
    {
    for(student t:Astudent)
    {
    if(t.getSunm().equals(q))
    {
    %>
    <tr aligh="center">
    <td><%=t.getSunm() %></td>
    <td><%=t.getName()%></td>
    <td><%=t.getSex() %></td>
    <td><%=t.getSclass() %></td>
    <td><%=t.getMajor() %></td>
    <br>
    </tr>
    <%
    }
    }
    }
    break;
    }
    }
    %>
    <td><a href="user.jsp">注销</a></td>
    <td><a href="loginS.jsp">返回上一级</a></td>
    </table>
    </form>
    </body>
    </html>

  • 相关阅读:
    c语言的注意事项(未完,以后遇到问题继续添加)
    const与指针的运用
    A7139射频模块wor配置解析
    lora项目注意事项(只用于本项目)
    串口通信数码管显示输入数字
    点阵图形上移
    按键弹起数字增加和按下增加
    数码管从999999倒计时
    中断与数码管秒表显示
    PHP控制连接打印机
  • 原文地址:https://www.cnblogs.com/fuxw4971/p/14159693.html
Copyright © 2011-2022 走看看