delallts.asp

来自「国内第一数字点卡销售程序。功能强大。 完整无错!数据文件经MD5加密!经严格测」· ASP 代码 · 共 117 行

ASP
117
字号
<!--#include file="conn.asp"-->
<%
set rs=server.createobject("adodb.recordset")
%>
<%
if session("admin_rank")<>1 and session("admin_rank")<>2 then
response.write("<script>alert('您无权查看本页,SORRY!');window.location=('login.asp')</script>")
response.end
end if
%>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" type="text/css" href="css.css">
</head>

<%
if request("action")="del" then
     sql="select * from ts where id="&int(request("id"))
    rs.open sql,conn,3,3
    if rs.eof then
        response.redirect "delallts.asp"
    else
    rs.delete
    rs.update
    end if
    rs.close
    response.write "<script language=javascript>alert('删除成功!');</script>"
end if
%>
<body style="background-color: #F0FBF1">

<div align="center">
<table border="1" width="764" cellspacing="0" height="112" bordercolorlight="#C0C0C0" bordercolordark="#FFFFFF" cellpadding="0">
               <tr> 
                <form method="POST" action="tssearch.asp">
                  
      <td style="padding-left: 10px" colspan="6" height="35"> 投诉查询:
        <input type="text" name="keywords" size="12" class=ipt>&nbsp;
        <input type="image" border="0" name="b12" src="../IMAGES/search.jpg" width="81" height="20">
        <font color="#FF0000">注:按投诉标题搜索</font><br>
      </td>
                </form>
              </tr>
  <%
  sql="select * from ts where zt=true order by id DESC"
  rs.open sql,conn,3,3
  if rs.eof then
      response.write "暂且没有已回复投诉"
      response.end
  end if   
      rs.pagesize=15
      page = cint(request("page"))
      if page = "" then page = 1
      if not(isnumeric(page)) then page=1
      if page<1 then page=1
      if page >= rs.pagecount then page = rs.pagecount
      rs.absolutepage = page
  %>
  

  <tr>
    <td width="61" align="center" height="35">
      投诉编号</td>
    <td width="191" align="center" height="35">
      投诉标题</td>
    <td width="266" align="center" height="35">
      内容</td>
    <td width="80" align="center" height="35">
      加入日期</td>
    <td width="40" align="center" height="35">
      状态</td>
    <td width="54" align="center" height="35">
      是否删除</td>
  </tr>
<%
for i=1 to rs.pagesize
%>
  <tr>
    <td width="61" align="center" height="35">
       <%=rs("id")%></td>
    <td width="191" align="center" height="35">
       <%=rs("title")%></td>
    <td width="266" align="center" height="35">
    <%=rs("content")%></td>
    <td width="80" align="center" height="35">
       <%=rs("ts_date")%></td>
    <td width="40" align="center" height="35">
     <%if rs("zt")=true then%><font color="#FF6600">已回复<%else%>未回复</font><%end if%></td>
    <td width="54" align="center" height="35">
      <a href="delallts.asp?id=<%=rs("id")%>&action=del" onClick="return confirm('您确定进行删除操作吗?')"><font color="#FF0000">删除</font></a></td>
  </tr>
<%
rs.movenext
if rs.eof then exit for
next
%>
                  <tr>         
                    <td width="-5" style="padding-left: 10px" colspan="6" height="35">        
                    <p align="center">共有记录<%=rs.recordcount%>条&nbsp;                   
                    <%=page%>/<%=rs.pagecount%>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <A href="<%request.servervariables("document_name")%>?page=<%=page-1%>">上一页</A> <A href="<%request.servervariables("document_name")%>?page=<%=page+1%>">下一页</A>&nbsp;&nbsp;&nbsp; 转到第 <SELECT onchange="window.location='?page='+this.value" name=gopage>              
                    <%for x=1 to rs.pagecount%>
                    <OPTION <%if x=page then%>selected<%end if%> value=<%=x%>><%=x%></OPTION>
                    <%next%>      
                    </SELECT> 页        
                    </div>
                    <%rs.close%>  
                    </td>     
                  </tr>  
  
</table>
</div>

<%
set rs=nothing
conn.close
set conn=nothing
%>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?