• Java自学


    11.25

    1完善图书管理系统

    复制代码
    <%@ page language="java" contentType="text/html; charset=UTF-8"
        pageEncoding="UTF-8"%>
    <!DOCTYPE html>
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
    <title>管理员</title>
    <style >
    .a{
            font-size: 26px;
            margin-top: 20px;
        }
        a{
            text-decoration: none;
        }
        a:hover {
        color: red;
    }
    </style>
    </head>
    <body>
    <div align="center">
    <h1 style="color: black;">管理员功能页</h1>
            <div class="a">
                <a href="tianjia.jsp">添加读者信息</a>
            </div>
            <div class="a">
                <a href="tianjia2.jsp">添加新书信息</a>
            </div>
            <div class="a">
                <a href="dayin.jsp">打印催还图书信息</a>
            </div>
    </div>
    </body>
    </html>
    复制代码
    复制代码
    <%@ 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;
        }
        .tb, td {
            border: 1px solid black;
            font-size: 22px;
        }
    </style>
    </head>
    <body>
        <div align="center">
            <h1 style="color: red;">人口信息</h1>
            <a href="duzhegong.jsp">返回主页</a>
        
            <table class="tb">
                <tr>
                    <td>编号</td>
                    <td>书名</td>
                    <td>作者名</td>
                    <td>出版社</td>
                    <td>可借阅数量</td>
            
                </tr>
                <!-- forEach遍历出adminBeans -->
                <c:forEach items="${holds}" var="item" varStatus="status">
                    <tr>
                        <td>${item.bianhao}</td>
                        <td><a>${item.shuming}</a></td>
                        <td>${item.zuozheming}</td>
                        <td>${item.chubanshe}</td>
                        <td>${item.kejieyueshuliang}</td>
            
                    </tr>
                    
                </c:forEach>
            </table>
        <form action="Servlet?method=jieyue" method="post" >
                
                <div class="a">
                    <button type="submit" class="b">借&nbsp;&nbsp;&nbsp;阅</button>
                </div>
            </form>
        </div>
    </body>
    </html>
    复制代码
    复制代码
    <%@ page language="java" contentType="text/html; charset=UTF-8"
        pageEncoding="UTF-8"%>
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="UTF-8">
    <title>借阅图书</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")%>");
                  var  asd=request.getAttribute("name");         
        </script>
        <%
            }
        %>
        <div align="center">
            <h1 style="color: red;">图书信息</h1>
            <a href="denglu.jsp">返回主页</a>
            
            <form action="Servlet?method=jieyue0" method="post" >
                <div class="a">
                    编号<input type="text" id="bianhao" name="bianhao"/>
                </div>
                <div class="a">
                    <button type="submit" class="b">查&nbsp;&nbsp;&nbsp;看</button>
                </div>
            </form>
        </div>
        
    </body>
    </html>
    复制代码

    2.session部分不太会

    3.继续web

  • 相关阅读:
    每日日报30
    每日作业报告
    每日作业报告
    每日作业报告
    每日作业报告
    每日作业报告
    每日作业报告
    每日作业报告
    每日作业报告
    Java学习的第四十三天
  • 原文地址:https://www.cnblogs.com/20193898liufa/p/14161524.html
Copyright © 2020-2023  润新知