<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!--#include file="../inc/conn.asp"-->
<!--#include file="../inc/Function.asp"-->
<%
Call ChkLogin(session("WebAdminsUserName"))
Call ConnectionDataBase(2)
Action = Request("Action")
Select Case Action
	Case "AddFiles"
		Call AddFiles
End Select
'上传文件
Sub AddFiles()
	FileCategory = Request.Form("FileCategory")
	FileName = Request.Form("FileName")
	UpFiles = Request.Form("UpFiles")	
	Url = Request.Form("Url")
	ID = Request.Form("ID")	
	SortID = Request.Form("SortID")	
	
	Call ChkIsNumber(ID,"参数类型错误!")
	Call ChkIsNull(FileName,"请输入广告名称!")
	Call ChkIsNull(UpFiles,"请选择上传文件!")
	Call ChkIsNumber(SortID,"参数类型错误!")
	IF Rec="" Then Rec=0
	strSql = "Select * From T_Ads Where ID=" & ID	
	SetRs Rs,strSql,conn,1,3
	IF Rs.EOF Then	Rs.Addnew()
	Rs("ClassID") = FileCategory
	Rs("FileName") = FileName	
	Rs("FilePath") = UpFiles	
	Rs("Url") = Url	
	Rs("SortID") = SortID	
	Rs.Update
	DisRs Rs
	Call CloseDatabase
	Call Success("信息提交成功!",Request.ServerVariables("HTTP_REFERER"))
End Sub
%>
