deltxlfiles.asp

来自「绿叶oa系统办公自动化 2008.工作日志管理,文件管理」· ASP 代码 · 共 36 行

ASP
36
字号
<!--#include file="../../Connections/oavbsconn.asp" -->
<%

if(request("id") <> "") then Command1__d = request("id")

%>
<%

set Command1 = Server.CreateObject("ADODB.Command")
Command1.ActiveConnection = MM_oavbsconn_STRING
Command1.CommandText = "DELETE FROM txlupfilessdfgdsffvdf WHERE  id=" + Replace(Command1__d, "'", "''") + ""
Command1.CommandType = 1
Command1.CommandTimeout = 0
Command1.Prepared = true
Command1.Execute()

%>
<%
dim p,objFSO
 p=request("p")
  Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
  
If objFSO.FileExists(Server.MapPath(p)) Then
objFSO.DeleteFile Server.MapPath(p),True
else%>
<script>
{
{alert("文件不存在,记录已删除!");history.go(-1)
}
</script>
<%response.end()
end if%>

<%response.redirect ("admintxlfiles.asp")%>

⌨️ 快捷键说明

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