⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 del.asp

📁 网人分类信息5.0商业版。非常优秀的分类信息系统。比较少见。
💻 ASP
字号:
<!--#include file="../inc/Conn.asp"-->
<!--#include file="../Inc/Cls.Common.asp"-->
<!--#include file="../Inc/Cls.Templates.asp"-->
<!--#include file="../Inc/Cls.Content.asp"-->
<!--#include file="../Inc/Cls.Create.asp"-->
<!--#include file="Channel_Config.asp"-->
<%
Dim ID,User,PostType,DelPass,Action,DelPass1
ID = WRMPS.CheckStr(Request("ID"),1)
If ID = "" Then Call WRMPS.ErrView("·操作错误",0)
Action = WRMPS.CheckStr(Request("Action"),0)
Select Case Action
  Case "Del"
    Call Del()
  Case Else
    Call Show()
End Select

Sub Del()
  DelPass1 = WRMPS.CheckStr(Request("DelPass"),0)
  If DelPass1 <> "" Then
    DelPass1 = MD5(2,DelPass1)
  Else
    Call WRMPS.ErrView("·请输入信息删除密码<meta http-equiv=refresh content='1;URL=Del.asp?ID="&ID&"'>",0)
  End If
  If Int(WR_ClassAD(1)) < 1 Then Call WRMPS.ErrView("·系统没有开启游客信息删除功能<br>·此界面 3 秒钟后自动关闭<script>function Close(){parent.closeWithIframe();}" & vbCrLf &"setTimeout(""Close()"",3000)</script>",0)
  Set Rs = Conn.Execute("Select WM_PostType,WM_DelPass,WM_Key From WM_ClassAD Where WM_ID="&ID)
  If Not Rs.Eof Then
	PostType = Rs(0)
	DelPass = Rs(1)
	Key = Rs(2)
	If PostType = 0 Then
	  If DelPass = "" or IsNUll(DelPass) Or DelPass <> DelPass1 Then
        Call WRMPS.ErrView("·信息删除密码不正确<meta http-equiv=refresh content='1;URL=Del.asp?ID="&ID&"'>",0)
	  Else
	    If Key = 1 Then
          Conn.Execute ("Update WM_Config Set WM_ClassNum = WM_ClassNum - 1 Where WM_ClassNum > 0")
          Call WRMPS.SCache("ClassNum",WRMPS.GetCache("ClassNum") - 1)
		End If
        Conn.Execute ("Delete From WM_ClassRevert Where WM_ParentID = " & ID & "")
        Set ClsCre = New Cls_Create
        Call ClsCre.CreClass("DEL",ID,1)
        Set ClsCre = Nothing
	    Call WRMPS.ErrView("·信息删除成功<br>·此界面 3 秒钟后自动关闭<script>function Close(){parent.closeWithIframe();parent.location='../'}" & vbCrLf &"setTimeout(""Close()"",3000)</script>",0)
	  End If
	End If
  Else
	Call WRMPS.ErrView("·内容不存在<br>·此界面 3 秒钟后自动关闭<script>function Close(){parent.closeWithIframe();}" & vbCrLf &"setTimeout(""Close()"",3000)</script>",0)
  End If
  Rs.Close
End Sub

Sub Show()
  Set Rs = Conn.Execute("Select WM_PostType,WM_Post From WM_ClassAD Where WM_ID="&ID)
  If Not Rs.Eof Then
    User = Rs(1)
	PostType = Rs(0)
	Select Case PostType
	  Case 0
         If Int(WR_ClassAD(1)) < 1 Then Call WRMPS.ErrView("·系统没有开启游客信息删除功能<br>·此界面 3 秒钟后自动关闭<script>function Close(){parent.closeWithIframe();}" & vbCrLf &"setTimeout(""Close()"",3000)</script>",0)
	     Response.Write "<link href="&UrlPath&"Skins/"&WR_Setting(5)&"/Style.css rel=stylesheet type=text/css>"
	     Response.write "<table width='100%' height='90%' border='0' cellspacing='0' cellpadding='0'>"
	     Response.write "<form name='form1' method='post' action='Del.asp'>"
	     Response.write "<input type=hidden name=Action value=Del>"
	     Response.write "<input type=hidden name=ID value="&ID&">"
	     Response.write "<tr><td height=20px><div style=""color:red;border:1px red solid;width:100%;margin:0 0 5px 0;padding:0 5px"">请输入信息删除密码</div></td></tr>"
	     Response.write "<tr><td align=center><input type='text' name='DelPass'>  <input type='submit' name='Submit' value='确定删除'></td></tr>"
	     Response.write "</form>"
	     Response.write "</table>"
	  Case 1
	    If Not WRUser.ChkLogin Then
		  Call WRMPS.AjaxLogin("../Member/User_ClassAD.asp?Action=Save$Work=Del$cID="&ID,1,"您需要登录后才可以删除此优惠券!")
		Else
		  If User <> MemName Then
		    Call WRMPS.ErrView("·您只能删除您自己发布的信息<br>·此界面 3 秒钟后自动关闭<script>function Close(){parent.closeWithIframe();}" & vbCrLf &"setTimeout(""Close()"",3000)</script>",0)
		  Else
		    Response.Write "正在删除,请等待......<script>function Close(){parent.closeWithIframe();parent.location='"&WRMPS.URLDecode("../Member/User_ClassAD.asp?Action=Save&Work=Del&cID="&ID)&"'}Close()</script>"
		  End If
		End If
	End Select
  Else
	Call WRMPS.ErrView("·内容不存在<br>·此界面 3 秒钟后自动关闭<script>function Close(){parent.closeWithIframe();}" & vbCrLf &"setTimeout(""Close()"",3000)</script>",0)
  End If
  Rs.Close
End Sub

Set Rs = Nothing
Call ClassEnd()
Call DBConnEnd()
%>

⌨️ 快捷键说明

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