📄 manrzdelall.asp
字号:
<%@ codepage ="936" %>
<%On Error Resume Next
Response.Buffer = True
Response.Expires = 0
Response.CacheControl = "Private"
Sub Msg (v)
Response.Write "<html><head><meta http-equiv='Content-Type' content='text/html; charset=gb2312'><meta http-equiv='pragma' content='no-cache'><style type=text/css>body{color:black;font-family:宋体;font-size:9pt;background-color:buttonface;border-bottom:medium none;border-left:medium none;border-right:medium none;border-top:medium none;padding-bottom:0px;padding-left:0px;padding-right:0px;padding-top:0px}</style></head><body leftMargin=0 topMargin=0 marginheight=0 marginwidth=0>"
Response.Write "<script Language=JavaScript>alert('" & v & "');window.close();</script></body></html>"
Response.End
End Sub
nickname=Session("hxf_u_nickname")
grade=Int(Session("hxf_u_grade"))
inthechat=Session("hxf_u_inthechat")
userip=Request.ServerVariables("REMOTE_ADDR")
usersystem=Request.ServerVariables("HTTP_USER_AGENT")
If nickname = "" Then Msg "不在聊天室中,不能删除!"
if Session("hxf_u_inthechat")<>"1" and nickname<>"聊天室管理员" then Msg "不在聊天室中,不能删除!"
If grade <> 12 or Int(Session("ipbt"))<>1 Then Msg "你不是聊天室管理员 \n\n 没有删除指定日志的权限!"
id = Request.QueryString("id")
If id = "" Or Not IsNumeric(id) Then Msg "没有指定删除日志的类型!"
id = Int(id)
If id < 0 Or id > 6 Then Msg "此日志的类型不存在!"
Select Case id
Case 0
logname = "日常管理日志"
Case 1
logname = "货币流通日志"
Case 2
logname = "级别调整日志"
Case 3
logname = "帐号管理日志"
Case 4
logname = "酷库管理日志"
Case 5
logname = "系统调整日志"
Case 6
logname = "超管登陆日志"
End Select
n = Year(Date)
y = Month(Date)
r = Day(Date)
s = Hour(Time())
f = Minute(Time())
m = Second(Time())
If Len(y) = 1 Then y = "0" & y
If Len(r) = 1 Then r = "0" & r
If Len(s) = 1 Then s = "0" & s
If Len(f) = 1 Then f = "0" & f
If Len(m) = 1 Then m = "0" & m
sjsfm = s & ":" & f & ":" & m
sj = n & "-" & y & "-" & r & " " & sjsfm
Set conn=Server.CreateObject("ADODB.CONNECTION")
Set rs=Server.CreateObject("ADODB.RecordSet")
connstr=Application("wsaxhg_connstr")
conn.open connstr
sql = "SELECT type FROM logs WHERE type = '" & id & "'"
rs.open sql, conn, 1, 1
If rs.Eof And rs.Bof Then
rs.Close
conn.Close
Set rs = Nothing
Set conn = Nothing
Msg "此日志目前没有记录!"
End If
rs.Close
sql = "DELETE FROM logs WHERE type = '" & id & "'"
conn.Execute sql
sql = "INSERT INTO logs (type, logtime, name, ip, opertion) VALUES ('5', '" & sj & "', '" & nickname & "', '" & userip & "', '清空了 <font color=red>[" & logname & "]</font> 操作者信息<font color=green><font class=p9>" & usersystem & "</font></font>')"
conn.Execute sql
conn.Close
Set rs = Nothing
Set conn = Nothing
Msg "已经清空 [" & logname & "] !"
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -