BVB Source Codes

Pcook CMS bubble guest v3.0 SDCMS version Show sdcms_comment.asp Source code

Return Download Pcook CMS bubble guest v3.0 SDCMS version: download sdcms_comment.asp Source code - Download Pcook CMS bubble guest v3.0 SDCMS version Source code - Type:.asp
  1. <!--#include file="sdcms_check.asp"-->
  2. <%
  3. set sdcms=new Sdcms_Admin
  4. sdcms.Check_admin
  5. sdcms.Check_lever 7
  6. set sdcms=nothing
  7. set sdcms=new sdcms_function
  8. classid=sdcms.Requestint(classid)
  9. set sdcms=nothing
  10. select case action
  11. case else:title="评论管理"
  12. end select
  13. sd_table="sd_comment"
  14. sd_table01="sd_count"
  15. sd_table02="sd_info"
  16. sdcms_head
  17. %>
  18. <div class="sdcms_notice"><span>管理操作:</span><a href="?">评论管理</a></div>
  19. <br>
  20.  
  21. <ul id="sdcms_sub_title">
  22.         <li class="sub"><%=title%></li>
  23. </ul>
  24. <div id="sdcms_right_b">
  25. <%
  26. select case action
  27. case "del":del
  28. case "pass":pass
  29. case else:main
  30. end select
  31. closedb
  32. sub main
  33. echo "<form name=""add"" action=""?"" method=""post""  onSubmit=""return confirm('确定要执行选定的操作吗?');"">"
  34.         page=request.querystring("page")
  35.         if page="" or not isnumeric(page) then
  36.         page=1
  37.         end if
  38.         pages =20
  39.         set rs=server.CreateObject("adodb.recordset")
  40.         if request("classid")<>0 then tj=" where infoid="&request("classid")&""
  41.         sql="select id,username,"
  42.         if Is_sql=0 then
  43.                 sql=sql&"(iif(ispass=1,'已审','未审'))"
  44.         else
  45.                 sql=sql&"(case ispass when 1 then '已审'else'未审' end)"
  46.         end if
  47.         sql=sql&",ip,adddate,content,ispass,infoid from "&sd_table&" "&tj&" order by ispass,id desc"
  48.        
  49.         rs.open sql,conn,1,1   
  50.         if rs.eof then
  51.         echo "没有资料"
  52.         else
  53.         rs.pagesize = pages
  54.         maxpagecount=rs.pagecount
  55.         rs.absolutepage = page
  56.         rcount1=0
  57.         pagestart=page-5
  58.         pageend=page+5
  59.         if pagestart<1 then
  60.         pagestart=1
  61.         end if
  62.         if pageend>maxpagecount then
  63.         pageend=maxpagecount
  64.         end if
  65.         rcount=rs.RecordCount
  66.         k=0
  67.         do while not rs.eof and rcount1 <rs.pagesize  
  68.         %>
  69.         <table border="0" align="center" cellpadding="3" cellspacing="1" class="table_b">
  70.         <tr>
  71.       <td class="title_bg" style="text-align:left"><span style="float:right"><%if rs(6)=0 then%><a href="?action=pass&id=<%=rs(0)%>&t=1&classid=<%=classid%>">通过验证</a><%else%><a href="?action=pass&id=<%=rs(0)%>&t=0&classid=<%=classid%>">取消验证</a><%end if%> <a href="?action=del&id=<%=rs(0)%>&classid=<%=classid%>" onclick='return confirm("真的要删除?不可恢复!");'>删除</a></span><input name="id"  type="checkbox" onClick="unselectall()"   value="<%=rs(0)%>"> <%=rs(1)%> 发表于:<%=rs(4)%> IP:<%=rs(3)%></td>
  72.    
  73.     </tr>
  74.     <tr onmouseover=this.bgColor='#EBFFDC'; onmouseout=this.bgColor='#ffffff';  bgcolor='#ffffff'>
  75.  
  76.       <td style="word-break:break-all;">
  77.         <%
  78.        
  79.         set sdcms_f=new sdcms_function
  80.         set rs1=conn.execute("select htmlname,classid,title from sd_info where id="&rs(7)&"")
  81.         if not rs1.eof then
  82.         echo "所属信息:<a "
  83.         echo "href="""&sdcms_root&sdcms_htmdir&sdcms_f.LoadRecord("classdir","sd_class",rs1(1))&rs1(0)&sdcms_filetxt&""" target=""_blank"">"   
  84.         echo ""&rs1(2)&"</a><br>"
  85.         end if
  86.         set sdcms_f=nothing
  87.         echo "评论内容:"&rs(5)&"</a>"
  88.         %></td>
  89.  
  90.    
  91.     </tr>
  92.  
  93.         </table><br>
  94.         <%
  95.         k=k+1
  96.         rs.movenext
  97.         rcount1=rcount1+1
  98.         loop
  99.         end if
  100.         if rcount>0 then      
  101.         %>
  102.         <table border="0" align="center" cellpadding="3" cellspacing="1" class="table_b">
  103.         <tr>
  104.       <td   class="tdbg" >
  105.           <span class="right">转到第
  106.                  <select onChange="location.href='?classid=<%=classid%>&page='+this.value+''">
  107.                  <%for i=1 to maxpagecount%>
  108.                  <option value="<%=i%>" <%if clng(page)=clng(i) then echo "selected" end if%>><%=i%></option>
  109.                  <%next%>
  110.                  </select>页</span> <input name="chkAll" type="checkbox" id="chkAll" onclick=CheckAll(this.form) value="checkbox"> 全选
  111.               <select name="action">
  112.                           <option>→操作</option>
  113.                           <option value="del">删除</option>
  114.                           </select>
  115.              
  116.       <input type="submit" class="bnt01" value="执行">
  117.  
  118. </td>
  119.     </tr>
  120.         <%if rcount>0 then%>
  121.         <tr>
  122.       <td   class="tdbg" align="center">
  123. <%
  124. if page<>"1" then
  125. echo "<a href=?page="&page-1&"&classid="&classid&">上一页</a> "
  126. else
  127. echo "上一页 "
  128. end if
  129. for i=pagestart to pageend
  130. if i=0 then
  131. i=1
  132. end if
  133. if i=clng(page) then
  134. str="<font color=red><b>"&i&"</b></font>"
  135. else
  136. str=i
  137. end if
  138. strurl="[<a href=?page="&i&"&classid="&classid&">"&str&"</a>]"
  139. echo strurl
  140. next
  141. if page=maxpagecount then
  142. echo " 下一页"
  143. elseif  page<>""&maxpagecount&"" then
  144. echo " <a href=?page="&page+1&"&stype="&stype&"&classid="&classid&">下一页</a>"
  145. else
  146. echo " 下一页"
  147. end if
  148. echo " 页次:"&page&"/"&maxpagecount&" 页   每页: "&pages&" 条  总数: "&rcount&" 条"
  149. %>
  150. </td>
  151.     </tr>
  152.         <%end if%>
  153.   </table>
  154. <%
  155. end if
  156. end sub
  157.  
  158. sub del
  159. if id<>"" then
  160. if instr(id,", ")>0 then
  161.         id=split(id,", ")
  162.                 for i=0 to ubound(id)
  163.                
  164.   conn.execute("Insert into sd_log (sdcms_name,ip,content) values('"&sdcms_adminname&"','"&sdcms_adminip&"','删除评论:编号为"&id(i)&"')")
  165.   infoid=conn.execute("select infoid from "&sd_table&" where id="&id(i)&"")(0)
  166.   conn.execute("update "&sd_table01&" set comment_num=comment_num-1 where id=1")
  167.   conn.execute("update "&sd_table02&" set comment_num=comment_num-1 where id="&infoid&"")
  168.   conn.execute("delete from "&sd_table&" where id="&id(i)&"")
  169.  Next
  170. Else
  171.         conn.execute("Insert into sd_log (sdcms_name,ip,content) values('"&sdcms_adminname&"','"&sdcms_adminip&"','删除评论:编号为"&id&"')")
  172.   conn.execute("update "&sd_table01&" set comment_num=comment_num-1 where id=1")
  173.   infoid=conn.execute("select infoid from "&sd_table&" where id="&id&"")(0)
  174.   conn.execute("update "&sd_table02&" set comment_num=comment_num-1 where id="&infoid&"")
  175.   conn.execute("delete from "&sd_table&" where id="&id&"")
  176. End if
  177. End if
  178.   response.Redirect("?classid="&classid&"")
  179. end sub
  180.  
  181. sub pass
  182. select case t
  183. case "0","1"
  184. case else:t=0
  185. end select
  186. if t=0 then
  187. conn.execute("Insert into sd_log (sdcms_name,ip,content) values('"&sdcms_adminname&"','"&sdcms_adminip&"','取消验证评论:编号为"&id&"')")
  188. else
  189. conn.execute("Insert into sd_log (sdcms_name,ip,content) values('"&sdcms_adminname&"','"&sdcms_adminip&"','通过验证评论:编号为"&id&"')")
  190. end if
  191. conn.execute("update "&sd_table&" set ispass="&t&" where id="&id&"")
  192. response.Redirect("?classid="&classid&"")
  193. end sub
  194.  
  195. %>  
  196. </div>
  197. </body>
  198. </html>
downloadsdcms_comment.asp Source code - Download Pcook CMS bubble guest v3.0 SDCMS version Source code
Related Source Codes/Software:
Oo 126 CMS movie site system - This procedure ASP + ACC/ASP + SQL, using new kern... 2016-09-21
IDC sales web site - Beautiful IDC sales web site source code 2016-09-21
NPOINT virtual host v1.7.0 formal version management system - The system main function is introduced 2016-09-21
Classified information network business in suzhou - Overall module: classification of supply and deman... 2016-09-21
Jie Yang v0.6.3 article system - System functions: 1, the system settings A confi... 2016-09-21
Age design website information management system SDCMS v1.1 SP1 - SDCMS is designed to build the information managem... 2016-09-21
Age design website information management system SDCMS v1.1 SP1 - SDCMS is designed to build the information managem... 2016-09-21
C9 v2.1.1 static post system - Program USES ASP + ACC structure design and develo... 2016-09-21
Imitation green download station perfect version - Before increased | software home page, on the basi... 2016-09-21
Subdomain hosting edition v1.9 s taobao, pat - The background site admin 2016-09-21
CRYENGINE - CRYENGINE is a powerful real-time game development... 2017-06-11
postal - 2017-06-11
reactide - Reactide is the first dedicated IDE for React web ... 2017-06-11
rkt - rkt is a pod-native container engine for Linux. It... 2017-06-11
uWebSockets - Tiny WebSockets https://for... 2017-06-11
realworld - TodoMVC for the RealWorld - Exemplary fullstack Me... 2017-06-11
goreplay - GoReplay is an open-source tool for capturing and ... 2017-06-10
pyenv - Simple Python version management 2017-06-10
redux-saga - An alternative side effect model for Redux apps ... 2017-06-10
angular-starter - 2017-06-10

 Back to top