gg.jsp
上传用户:helenhuo66
上传日期:2007-06-01
资源大小:865k
文件大小:3k
源码类别:

百货/超市行业

开发平台:

Java

  1. <%@ page contentType="text/html;charset=GBK" language="java" import="java.sql.*" errorPage="" %>
  2. <%@ include file="conn.jsp"%>
  3. <%
  4. if(session.getAttribute("admin_name")==null){
  5. ;}else{
  6. %>
  7. <%
  8. sql="select title,id,msg from pub  order by id desc";
  9. rs=mdb.executeQuery(sql);
  10. %>
  11. <html>
  12. <head>
  13. <title>公告管理</title>
  14. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  15. <link href=../css.css rel=STYLESHEET type=text/css>
  16. </head>
  17. <body bgcolor="#FFFFFF">
  18. <center>
  19. <table width="600" bordercolor="#FFFFFF">
  20.     <tr> 
  21.       <td width="60%" bordercolor="#ffcc99" rowspan="2">
  22.         <table width="311" border="1" cellspacing="0" bordercolor="#C0C0C0" style="border-collapse: collapse" cellpadding="0">
  23.           <%while(rs.next()){%>
  24.           <tr> 
  25.             <td bordercolor="#C0C0C0" width="196" bgcolor="#FFFFFF">
  26.               <div align="center"><%=rs.getString("title")%></div>
  27.             </td>
  28.             <td bordercolor="#C0C0C0" width="105" bgcolor="#FFFFFF"> 
  29.               <div align="center"><a href="ggdel.jsp?id=<%=rs.getInt("id")%>"><font color="#FF0000">删除</font></a></div>
  30.             </td>
  31.           </tr>
  32.           <tr> 
  33.             <td bordercolor="#C0C0C0" colspan="2"><%=rs.getString("msg")%> </td>
  34.           </tr>
  35.           <%
  36. }
  37.         %>
  38.         </table>
  39.       </td>
  40.       <td height="220"> 
  41.         <div align="center"> 
  42.           <form method="post" action="gg2.jsp">
  43.             <table width="200" border="1" bordercolor="#C0C0C0" cellspacing="0" height="200" style="border-collapse: collapse" cellpadding="0">
  44.               <tr bordercolor="#FFFFFF"> 
  45.                 <td> 
  46.                   <div align="center">发布新公告</div>
  47.                 </td>
  48.               </tr>
  49.               <tr> 
  50.                 <td> 
  51.                   <div align="center">主题</div>
  52.                 </td>
  53.               </tr>
  54.               <tr bordercolor="#FFFFFF"> 
  55.                 <td> 
  56.                   <div align="center"> 
  57.                     <input type="text" name="title" size="20">
  58.                   </div>
  59.                 </td>
  60.               </tr>
  61.               <tr> 
  62.                 <td> 
  63.                   <div align="center">公告内容 </div>
  64.                 </td>
  65.               </tr>
  66.               <tr bordercolor="#FFFFFF"> 
  67.                 <td> 
  68.                   <div align="center"> 
  69.                     <textarea name="msg" wrap="VIRTUAL" rows="6" cols="20"></textarea>
  70.                   </div>
  71.                 </td>
  72.               </tr>
  73.               <tr bordercolor="#FFFFFF"> 
  74.                 <td> 
  75.                   <div align="center"> 
  76.                     <input type="submit" class="buttonface" name="Submit" style="position: relative; height: 19" value="确 定">&nbsp;&nbsp;
  77.                     <input type="reset" class="buttonface" name="Submit2" style="position: relative; height: 19" value="重 置">
  78.                   </div>
  79.                 </td>
  80.               </tr>
  81.             </table>
  82.           </form>
  83.         </div>
  84.       </td>
  85.     </tr>
  86.   </table>
  87. </center>
  88. </body>
  89. </html>
  90. <%
  91. mdb.Close();}%>