ht_list.asp
Upload User: pengwei803
Upload Date: 2021-02-10
Package Size: 3311k
Code Size: 5k
Development Platform:

HTML/CSS

  1. <!--#include file="../Ku_inc/Ku_sql.asp"-->
  2. <!--#include file="../Ku_inc/Ku_config.asp"-->
  3. <!--#include file="Ku_conn.asp"-->
  4. <!--#include file="../Ku_inc/Ku_md5.asp"-->
  5. <!--#include file="../Ku_inc/inc.asp"-->
  6. <!-- #include file="Session.asp"-->
  7. <html>
  8. <head>
  9. <title>内容列表</title>
  10. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  11. <link href="include/style.css" rel="stylesheet" type="text/css">
  12. <style type="text/css">
  13. <!--
  14. input{
  15. height:22px;
  16. border:1px solid #BEBEBE;
  17. background-color:#FFF;
  18. padding-top: 2px;
  19. padding-right: 8px;
  20. padding-bottom: 0pt;
  21. padding-left: 3px;
  22. }
  23. -->
  24. </style>
  25. </head>
  26. <body>
  27. <script language="JavaScript" type="text/javascript">
  28. function checkall(form)
  29. {
  30. for (var i=0;i<form.elements.length;i++)    {
  31. var e = form.elements[i];
  32. if (e.name != 'chkall') e.checked = form.chkall.checked; 
  33. }
  34. }
  35. </script>
  36. <table width="94%" border="0" align="center" cellpadding="0" cellspacing="0">
  37.   <tr>
  38.   <td height="30" style="border: 1px solid #D0D4D9" bgcolor="#EEEEEE"><b> 当前栏目:&gt; </b>
  39. 圈子话题管理</td>
  40.   </tr>
  41. </table>
  42. <table width="95%" border="0" align="center" cellpadding="3" cellspacing="1">
  43.   <tr>
  44.     <td width="30%">
  45.       &nbsp;<input class="input_back" type="button" name="Submit" value="圈子管理"onclick="location.href='quan_list.asp'"/> 
  46.       <input class="input_back" type="button" name="Submit" value="圈子帖子"onclick="location.href='Ht_list.asp'"/>      
  47. <input class="input_back" type="button" name="Submit0" value="管理首页"onclick="location.href='main.asp'"/></td>
  48.     <td width="29%">
  49.        </td>
  50. <form method="post" action="?" name="myKeyword">
  51.     <td width="40%">
  52.     <div align="right">搜索:
  53.         <input name="myKeyword" type="text" id="myKeyword" value="" style="WIDTH:30%" maxlength="50">
  54.         <input type="submit" name="Submit" value="搜索(S)" class="input_back">
  55.     </div>
  56.     </td>
  57.     </form>
  58.   </tr>
  59. <form action="deal_ht.asp?action=del" method=post name="thisform">
  60. <tr>
  61. <td colspan="3"><table width="100%" border="0" align="center" cellpadding="3" cellspacing="1" bgcolor="cecfce">
  62. <tr>
  63. <td width="6%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">操作</div></td>  
  64. <td height="25" bgcolor="e7ebef" style="font-weight: bold" width="33%">主题</td>
  65. <td width="14%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">
  66. 发布人</div></td>
  67. <td width="14%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">
  68. 所属圈子</div></td>
  69. <td width="17%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">日期</div></td>
  70. <td width="12%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">操作</div></td>
  71. <%
  72. set rs=server.createobject("adodb.recordset")
  73. if request.querystring("id")="" then
  74. sql="select * from [quan_ht] where 1=1 "
  75. else
  76. sql="select * from [quan_ht] where qid="&request.querystring("id")&""
  77. end if
  78. if not (Trim(Request("pageID"))="" or isempty(Trim(Request("pageID"))) ) then
  79. sql=sql&" and pageID="&clng(Request("pageID"))&""
  80. end if
  81. if not (Trim(Request("myKeyword"))="" or isempty(Trim(Request("myKeyword"))) ) then
  82. sql=sql&" and (title like '%" & Trim(Request("myKeyword")) & "%' or content like  '%" & Trim(Request("myKeyword")) & "%')"
  83. end if
  84. sql=sql&" order by addtime desc"
  85. 'response.write sql
  86. 'response.End
  87. rs.open sql,conn,1,1
  88. dim a
  89. Set a=New PageList
  90. listLimit=15
  91. '模拟分页一页显示分页数
  92. pageLists=5
  93. '设置分页参数
  94. If rs.BOF or rs.EOF Then 
  95. %>
  96. </tr>
  97. <tr bgcolor="#C6E3F4">
  98.   <td height="28" colspan="6" align="center" bgcolor="#FFFFFF">暂无记录!</td>
  99.   </tr>
  100. <%
  101. else
  102. '分页循环开始
  103. totalList=rs.recordcount
  104. a.InitPara=array(totalList,listLimit,pageLists)
  105. a.PageList()
  106. rs.pagesize=listLimit
  107. page = request("page")
  108. If page="" Then
  109. page=1
  110. End If
  111. rs.absolutepage = page
  112. for i=1 to rs.pagesize
  113. %>
  114. <tr bgcolor="#ffffff" onMouseOver='this.style.backgroundColor="#F6f6f6"' 
  115. onMouseOut='this.style.backgroundColor="#FAFAFA"'>
  116. <td height="28" align="center"><input type="checkbox" name="ID" value="<%=Trim(rs("ID"))%>"></td>
  117. <td width="33%"><a href="../Gu_showtie.asp?guxing=<%=rs("id")%>"><%=Trim(rs("title"))%></a></td>
  118. <td align="center"><a href="../userinfo.asp?user=<%=rs("fbr")%>"><%=Trim(rs("fbr"))%></a></td>
  119. <%
  120. cid=rs("qid")
  121. set kurs=server.createobject("adodb.recordset")
  122.     csql="select * from quan where id="&cid
  123.     kurs.open csql,conn,1,3
  124. %>
  125. <% do while not kurs.eof%>
  126. <td align="center"><%=kurs("name")%></td>
  127. <td align="center"><%=Trim(rs("addtime"))%></td>
  128. <td align="center"> 
  129. <a href="deal_ht.asp?action=del&id=<%=rs("id")%>">删除</a></td>
  130. <%
  131.    kurs.movenext
  132.    loop
  133.    kurs.close
  134.    
  135. %>
  136. </tr>
  137. <%
  138. rs.movenext
  139. if rs.eof then exit for
  140. next
  141. end if
  142. %>
  143. </table></td>
  144.   </tr>
  145.   <tr>
  146.     <td colspan="3"><div align="right">
  147.           <input type=checkbox name=chkall value=on onClick="checkall(this.form)">全部选中<input type=submit name=action onClick="{if(confirm('确定删除选定的纪录吗?')){this.document.thisform.submit();return true;}return false;}" value="批量删除(D)" class="input_back">
  148.     </div></td>
  149.   </tr>
  150.   <tr>
  151.     <td colspan="3"><%=a.PageInfo%></td>
  152.   </tr>
  153.   <tr>
  154.     <td colspan="3"></td>
  155.   </tr>
  156.  </form>
  157. </table>
  158. <%
  159. rs.close
  160. set rs=nohing
  161. %>
  162. <hr/>
  163. <br>
  164. <p align="center"><!-- #include file="Ku_bottom.asp"--></p>
  165. </body>
  166. </html>