这是Photo_save.asp相册保存过程的一段代码:我想修改成不保存图片,我把红色部分删除后出错了,请版主帮忙看一下!<%
dim rs
,str_tmppic,i_s,str_tmppicarr,p_FolderObj,p_FSO,p_FileObj
Set p_FSO = Server.CreateObject(G_FS_FSO)if Request.Form("Action")="add" then
str_tmppic=Replace(Request.Form("pic_1")&"|"&Request.Form("pic_2")&"|"&Request.Form("pic_3")," ","")
str_tmppicarr =split(str_tmppic,"|")
for i_s=0 to Ubound(str_tmppicarr)
if str_tmppicarr(i_s)<>"" then
If Left(LCase(str_tmppicarr(i_s)),7) <> "http://" And Left(str_tmppicarr(i_s),1) = "/" then
p_FolderObj = p_FSO.GetFile(Server.MapPath(Replace(str_tmppicarr(i_s),"/","\"))).size
Else
p_FolderObj = 0
End If
set rs= Server.CreateObject(G_FS_RS)
rs.open "select * From FS_ME_Job where 1=0",User_conn,1,3
rs.addnew
rs("title")=Request.Form("title")
rs("age")=Request.Form("age")
rs("gender")=Request.Form("gender")
rs("EndDate")=Request.Form("EndDate")
rs("speciality")=Request.Form("speciality")
rs("edus")=Request.Form("edus")
rs("num")=Request.Form("num")
rs("assess")=Request.Form("assess")
rs("txtProv")=Request.Form("txtProv")
rs("txtCity")=Request.Form("txtCity")
rs("experience")=Request.Form("experience")
rs("jobtypes")=Request.Form("jobtypes")
rs("emolument")=Request.Form("emolument")
rs("EndDate")=Request.Form("EndDate")
rs("PicSavePath")=str_tmppicarr(i_s) rs("Content")=NoHtmlHackInput(Request.Form("Content"))
rs("Addtime")=now
if Request.Form("ClassID")<>"" then
rs("ClassID")=clng(Request.Form("ClassID"))
else
rs("ClassID")=0
end if
rs("PicSize")=p_FolderObj rs("Hits")=0
rs("UserNumber")=Fs_User.UserNumber
rs.update
rs.close:set rs=nothing
end if
next
strShowErr="<li>保存信息成功</li>"
Response.Redirect("lib/Success.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl=../Job_Manage.asp")
Response.end
elseif Request.Form("Action")="edit" then
If Left(LCase(Request.Form("pic_1")),7) <> "http://" And Left(Request.Form("pic_1"),1) = "/" then
p_FolderObj = p_FSO.GetFile(Server.MapPath(Replace(Request.Form("pic_1"),"/","\"))).size
Else
p_FolderObj = 0
End If set rs= Server.CreateObject(G_FS_RS)
rs.open "select * From FS_ME_Job where id="&Clng(Request.Form("id")),User_conn,1,3
rs("title")=Request.Form("title")
rs("age")=Request.Form("age")
rs("gender")=Request.Form("gender")
rs("EndDate")=Request.Form("EndDate")
rs("speciality")=Request.Form("speciality")
rs("edus")=Request.Form("edus")
rs("num")=Request.Form("num")
rs("assess")=Request.Form("assess")
rs("txtProv")=Request.Form("txtProv")
rs("txtCity")=Request.Form("txtCity")
rs("experience")=Request.Form("experience")
rs("jobtypes")=Request.Form("jobtypes")
rs("emolument")=Request.Form("emolument")
rs("EndDate")=Request.Form("EndDate")
rs("PicSavePath")=Request.Form("pic_1") rs("Content")=NoHtmlHackInput(Request.Form("Content"))
if Request.Form("ClassID")<>"" then
rs("ClassID")=clng(Request.Form("ClassID"))
else
rs("ClassID")=0
end if
rs("PicSize")=p_FolderObj rs.update
rs.close:set rs=nothing
strShowErr="<li>修改信息成功</li>"
Response.Redirect("lib/Success.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl=../Job_Manage.asp")
Response.end
end if
set p_FSO=nothingset Fs_User=nothing
%>