📄 rdownload_dele.asp
字号:
<%
'功能:删除档案库
'参数:request("id")#要删除档案库的ID
%>
<!--#include file="../inc/Secure.asp"-->
<!--#include file="../inc/conn.asp"-->
<!--#include file="../inc/Const.asp"-->
<%
'response.buffer=false
'------------------------------------------------设置参数
LoginID=trim(session("LoginID")) : if LoginID="" then LoginID=0 '当前用户ID
cid=request("id") '档案库ID
Typeid=request("Typeid") : if Typeid="" then Typeid=0 '当前栏目ID
'------------------------------------------------
'------------------------------------------------删除记录
dirempty=true
sqlstr="select top 1 * from tbioaDownload_sort where pid="&cid
set rs=Server.CreateObject("ADODB.RecordSet")
rs.open sqlstr,oconn,1,1
if not rs.eof then
dirempty=false
end if
rs.close
sqlstr="select top 1 * from tbioaDownloadFile where typeid="&cid
set rs=Server.CreateObject("ADODB.RecordSet")
rs.open sqlstr,oconn,1,1
if not rs.eof then
dirempty=false
end if
rs.close
set rs=nothing
if dirempty then
oConn.Execute "DELETE FROM tbioaDownload_sort WHERE ID="&cid
errmsg="已成功删除!"
else
errmsg="删除失败,该目录为非空目录!"
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="../css/main.css" type=text/css>
<title>main</title>
<base target="FrmMain">
</head>
<body topmargin="10" leftmargin="10">
<!--#include file="menu.html"-->
<hr width="100%" size=1 color="#000000">
<br>
<div align="center">
<table width="400" cellspacing="1" cellpadding="2" class="tab">
<tr>
<td width="100%" class="tdTop">
<table border="0" width="100%" cellspacing="0" cellpadding="0">
<tr>
<td class="tdTop">
<p align="left"><img border="0" src="../images/icon_title.gif" align="left">删除档案库</p>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="25%" class="td1">
<table border="0" width="100%" cellspacing="10" cellpadding="0">
<tr>
<td width="36%">
<p align="right"><img border="0" src="../images/edit.gif" width="32" height="32">
</td>
<td width="64%"><p> </p>
<p><%=errmsg%></p>
<p><img border="0" src="../images/icon_return.gif" align="left"><a href="RDownload_index.asp?typeid=<%=typeid%>">返回档案库</a>
</td>
</tr>
<tr>
<td width="100%" colspan="2">
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="25%" class="tdBottom">
</td>
</tr>
</table>
</div>
</body>
</html>
<%'释放对象变量
'oConn.close
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -