<% if CheckUserLogined()=False then response.Redirect "User_Login.asp" end if dim PhotoID,sql,rs,FoundErr,ErrMsg,PurviewChecked dim ClassID,tClass,ClassName,RootID,ParentID,ParentPath,Depth,ClassMaster PhotoID=trim(request("PhotoID")) FoundErr=False PurviewChecked=False call main() if FoundErr=True then WriteErrMsg() end if call CloseConn() sub main() if PhotoId="" then FoundErr=True ErrMsg=ErrMsg & "
  • 参数不足
  • " exit sub else PhotoID=Clng(PhotoID) end if sql="select * from Photo where Deleted=False and PhotoID=" & PhotoID & "" Set rs= Server.CreateObject("ADODB.Recordset") rs.open sql,conn,1,1 if rs.bof and rs.eof then FoundErr=True ErrMsg=ErrMsg & "
  • 找不到文章
  • " else ClassID=rs("ClassID") set tClass=conn.execute("select ClassName,RootID,ParentID,Depth,ParentPath,ClassMaster From PhotoClass where ClassID=" & ClassID) if tClass.bof and tClass.eof then founderr=True ErrMsg=ErrMsg & "
  • 找不到指定的栏目
  • " else ClassName=tClass(0) RootID=tClass(1) ParentID=tClass(2) Depth=tClass(3) ParentPath=tClass(4) ClassMaster=tClass(5) end if set tClass=nothing end if if FoundErr=True then rs.close set rs=nothing exit sub end if if rs("Editor")=UserName and rs("Passed")=False then PurviewChecked=True else PurviewChecked=False end if %> <%=rs("PhotoName")%>

    <%= dvhtmlencode(rs("PhotoName")) %>

    图片大小: <%= rs("PhotoSize") & " K" %>
    <% if FoundErr<>True then response.write "" else response.write "" end if%>
    <%response.write "" & dvhtmlencode(rs("PhotoName")) & ""%>
    图片作者: <% if rs("Author")="" then response.write "佚名" else response.write dvhtmlencode(rs("Author")) end if%>
    更新时间: <%= rs("UpdateTime") %>
    推荐等级: <%= string(rs("Stars"),"★") %>
    查看次数: 本日:<%=rs("DayHits")%>  本周:<%=rs("WeekHits")%>  本月:<%=rs("MonthHits")%>  总计:<%=rs("Hits")%>
    图片添加: <%= rs("Editor") %>
    图片简介: <%= dvhtmlencode(rs("PhotoIntro")) %>
    查看图片: <% if FoundErr=True then response.write ErrMsg else response.write "图片地址一" & "" if rs("PhotoUrl2")<>"" then response.write "    图片地址二" & "" if rs("PhotoUrl3")<>"" then response.write "    图片地址三" & "" if rs("PhotoUrl4")<>"" then response.write "    图片地址四" & "" end if %>
    可用操作: <% if PurviewChecked=True then response.write "修改  " response.write "删除  " end if %>
    <% end sub %>