📄 user_flashdel.asp
字号:
<!--#include file="conn.asp"-->
<!--#include file="config.asp"-->
<%
if session("username")="" then
call mb("对不起,您还没有登陆!","login.asp",1)
end if
dim id
id=request("id")
if not isinteger(id) then
call mb("请指定要删除的Flash的ID参数!","",0)
end if
set rs=server.createobject("adodb.recordset")
sql="select * from flash where id="&id
rs.open sql,conn,1,3
if rs.bof and rs.eof then
call mb("对不起,找不到您要删除的Flash!","",0)
elseif rs("username")<>session("username") then
call mb("对不起,您无权删除别人发布的作品!","",0)
else
'重新统计大类Flash数
conn.execute("update bigclass set flashcount=flashcount-1 where bigclassid="&rs("bigclassid")&" and flashcount>0")
'重新统计小类Flash数
conn.execute("update smallclass set flashcount=flashcount-1 where smallclassid="&rs("smallclassid")&" and flashcount>0")
'统计作者Flash数
conn.execute("update author set flashnum=flashnum where username='"&rs("username")&"' and flashnum>0")
'删除Flash
rs.delete
rs.update
end if
rs.close
set rs=nothing
conn.close
set conn=nothing
call mb("删除Flash成功!","user_index.asp",1)
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -