index.jsp
上传用户:manager48
上传日期:2022-07-31
资源大小:997k
文件大小:3k
源码类别:

Jsp/Servlet

开发平台:

Java

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml" >
  3. <%@page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" errorPage="" %>
  4. <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
  5. <head>
  6. <title>网盟留言本</title>
  7. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  8. <meta name="author" content="jezz" />
  9. <link href="images/web.css" rel="stylesheet" type="text/css">
  10. <jsp:useBean id="mypage" class="wm.bean.page" scope="page"/>
  11. </head>    
  12. <body>
  13. <div id="wrapper">
  14.         <div id="header">
  15.                  <div id="logo"></div>
  16.                         <div id="blog-header">
  17.                             <h1 class="blog-title"><a href="index.jsp">WMgbook 1.0</a></h1>
  18.                             <div class="blog-desc">欢迎光临网盟留言本</div>
  19.                         </div>
  20.                         <div id="menu">
  21.                             <ul>
  22.                                 <li><a href="index.jsp">留言首页</a></li>
  23.                                 <li><a href="new.jsp">签写留言</a></li>
  24.                                 <li><a href="http://www.wangmeng.cn" target="_blank">官方网站</a></li>
  25.                             </ul>
  26.                         </div><!--menu -->
  27.                    
  28.         </div><!--header -->
  29.         
  30. <div id="mainWrapper">
  31.                     <div id="content" class="content-wide">
  32.                         
  33.                      
  34. <%
  35.  ResultSet rs = mypage.myQuery(request,response,10);
  36.          while(rs.next())
  37.         {
  38.         
  39.         String email = rs.getString("email") ;
  40.         String content = rs.getString("content") ;
  41. String restore=rs.getString("restore");
  42. String restore_time=rs.getString("restore_time");
  43. request.setAttribute("restore",restore);
  44.         
  45.         %>
  46.  
  47.                <div class="textbox">
  48. <div class="textbox-title">
  49. <div class="textbox-label">[ <%=rs.getString("sj")%> | 留言者: <%=rs.getString("xm")%> ]</div>
  50. </div>
  51. <div class="textbox-content"><%=content%></div>
  52. <c:if test="${!empty restore}">
  53. <div class="textbox-content-reply"><%=restore%><div class="text-box-replytime">回复时间:<%=restore_time%></div></div>
  54. </c:if>
  55. <div class="textbox-bottom">邮箱: <%=email%> <c:if test="${!empty login}">| <a href="reply.jsp?id=<%=rs.getString("id")%>">回复</a> | <a href="del.jsp?id=<%=rs.getString("id")%>" onclick="javascript:return confirm('Delete message!nAre you sure?');">删除</a></c:if></div>
  56.   </div><!--textbox -->
  57. <%
  58.         }
  59.         String footer = mypage.PageFooter();
  60.        
  61.         %>
  62.  <div class="article-bottom">
  63.                <div class="pages">
  64.                                <%out.println(footer);%>
  65.                                 </div>
  66.                             </div><!--article-bottom -->
  67.                       
  68.                     </div><!--content -->
  69.                 </div><!--mainWrapper -->
  70.                 <div id="footer">
  71.                     <div id="innerFooter">Powered by WMgbook 1.0&#8482; Copyright &copy;</div>
  72.                 </div>
  73.             
  74.         </div>
  75. <% rs.close();
  76. mypage.all_close();%>    
  77. </body>
  78. </html>