Quan_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>圈子管理</td>
  39.   </tr>
  40. </table>
  41. <table width="95%" border="0" align="center" cellpadding="3" cellspacing="1">
  42.   <tr>
  43.     <td width="30%">
  44.   <input class="input_back" type="button" name="Submit" value="圈子类型"onclick="location.href='quan_kind.asp'"/>      
  45. <input class="input_back" type="button" name="Submit0" value="管理首页"onclick="location.href='main.asp'"/></td>
  46.     <td width="22%">
  47.        </td>
  48. <form method="post" action="?" name="myKeyword">
  49.     <td width="46%">
  50.     <div align="right">搜索:
  51.         <input name="myKeyword" type="text" id="myKeyword" value="" style="WIDTH:30%" maxlength="50">
  52.         <input type="submit" name="Submit" value="搜索(S)" class="input_back">
  53.     </div>
  54.     </td>
  55.     </form>
  56.   </tr>
  57. <form action="deal_quan.asp?action=delquan" method=post name="thisform">
  58. <tr>
  59. <td colspan="3"><table width="100%" border="0" align="center" cellpadding="3" cellspacing="1" bgcolor="cecfce">
  60. <tr>
  61. <td width="3%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">操作</div></td>  
  62. <td height="25" bgcolor="e7ebef" style="font-weight: bold" width="42%">
  63. <p align="center">圈 子 名 称</td>
  64. <td width="10%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">创建人</div></td>
  65. <td width="10%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">
  66. 分类</div></td>
  67. <td width="13%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">日期</div></td>
  68. <td width="19%" bgcolor="e7ebef" style="font-weight: bold"><div align="center">操作</div></td>
  69. <%
  70. set rs=server.createobject("adodb.recordset")
  71. if request("nameid")="" then
  72. sql="select * from [quan] where 1=1 "
  73. else
  74. sql="select * from [quan] where lb='"&request("nameid")&" '"
  75. end if
  76. if not (Trim(Request("pageID"))="" or isempty(Trim(Request("pageID"))) ) then
  77. sql=sql&" and pageID="&clng(Request("pageID"))&""
  78. end if
  79. if not (Trim(Request("myKeyword"))="" or isempty(Trim(Request("myKeyword"))) ) then
  80. sql=sql&" and (name like '%" & Trim(Request("myKeyword")) & "%' or beizhu like  '%" & Trim(Request("myKeyword")) & "%')"
  81. end if
  82. sql=sql&" order by addtime desc"
  83. 'response.write sql
  84. 'response.End
  85. rs.open sql,conn,1,1
  86. dim a
  87. Set a=New PageList
  88. listLimit=15
  89. '模拟分页一页显示分页数
  90. pageLists=5
  91. '设置分页参数
  92. If rs.BOF or rs.EOF Then 
  93. %>
  94. </tr>
  95. <tr bgcolor="#C6E3F4">
  96.   <td height="28" colspan="6" align="center" bgcolor="#FFFFFF">暂无记录!</td>
  97.   </tr>
  98. <%
  99. else
  100. '分页循环开始
  101. totalList=rs.recordcount
  102. a.InitPara=array(totalList,listLimit,pageLists)
  103. a.PageList()
  104. rs.pagesize=listLimit
  105. page = request("page")
  106. If page="" Then
  107. page=1
  108. End If
  109. rs.absolutepage = page
  110. for i=1 to rs.pagesize
  111. %>
  112. <tr bgcolor="#ffffff" onMouseOver='this.style.backgroundColor="#F6f6f6"' 
  113. onMouseOut='this.style.backgroundColor="#FAFAFA"'>
  114. <td height="28" align="center"><input type="checkbox" name="ID" value="<%=Trim(rs("ID"))%>"></td>
  115. <td width="42%" align="center"><a href="../My_quan.asp?id=<%=rs("id")%>"><%=Trim(rs("name"))%></a></td>
  116. <td align="center"><%=Trim(rs("cjr"))%></td>
  117. <%
  118. cid=rs("lb")
  119. set kurs=server.createobject("adodb.recordset")
  120.     csql="select * from Quan_type where name='"&cid&"'"
  121.     kurs.open csql,conn,1,3
  122. %>
  123. <% do while not kurs.eof%>
  124. <td align="center"><%=kurs("name")%></td>
  125. <td align="center"><%=Trim(rs("addtime"))%></td>
  126. <td align="center">&nbsp;<a href="Quan_edit.asp?quanid=<%=rs("id")%>">编辑</a> 
  127. <a href="deal_quan.asp?action=delquan&id=<%=rs("id")%>">删除</a></td>
  128. <%
  129.    kurs.movenext
  130.    loop
  131.    kurs.close
  132.    
  133. %>
  134. </tr>
  135. <%
  136. rs.movenext
  137. if rs.eof then exit for
  138. next
  139. end if
  140. %>
  141. </table></td>
  142.   </tr>
  143.   <tr>
  144.     <td colspan="3"><div align="right">
  145.           <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">
  146.     </div></td>
  147.   </tr>
  148.   <tr>
  149.     <td colspan="3"><%=a.PageInfo%></td>
  150.   </tr>
  151.   <tr>
  152.     <td colspan="3"></td>
  153.   </tr>
  154.  </form>
  155. </table>
  156. <%
  157. rs.close
  158. set rs=nohing
  159. %>
  160. <hr/>
  161. <br>
  162. <p align="center"><!-- #include file="Ku_bottom.asp"--></p>
  163. </body>
  164. </html>