%@language=vbscript codepage=936 %>
<%
option explicit
response.buffer=true
%>
<%
if CheckUserLogined()=False then
response.Redirect "User_Login.asp"
end if
dim PhotoID,rsPhoto,sql,FoundErr,ErrMsg
dim ClassID,SkinID,LayoutID,SkinCount,LayoutCount,ClassMaster,BrowsePurview,AddPurview
PhotoID=trim(request("PhotoID"))
if PhotoID="" then
FoundErr=True
ErrMsg=ErrMsg & "
请指定要修改的图片ID
"
call WriteErrMsg()
call CloseConn()
response.end
else
PhotoID=CLng(PhotoID)
end if
sql="select * from Photo where PhotoID=" & PhotoID & ""
Set rsPhoto= Server.CreateObject("ADODB.Recordset")
rsPhoto.open sql,conn,1,1
if rsPhoto.bof and rsPhoto.eof then
FoundErr=True
ErrMsg=ErrMsg & "
找不到文章
"
else
if rsPhoto("Editor")=request.Cookies("asp163")("UserName") then
if rsPhoto("Passed")=True then
FoundErr=True
ErrMsg=ErrMsg & "
图片已经被审核通过,你不能再进行修改!
"
end if
else
FoundErr=True
ErrMsg=ErrMsg & "
你不能修改其他人添加的图片!
"
end if
end if
if FoundErr=True then
call WriteErrMsg()
else
ClassID=rsPhoto("ClassID")
%>
修改图片
<%
end if
rsPhoto.close
set rsPhoto=nothing
call CloseConn()
%>