%@language=vbscript codepage=950 %> <% Set rs=Server.CreateObject("ADODB.RecordSet") Set rs1=Server.CreateObject("ADODB.RecordSet") session("useridname")=Request.cookies("ly")("useridname") session("useridpassword")=Request.cookies("ly")("useridpassword") if session("useridname")<>"" then rs.open "select level1 from register where username='"&session("useridname")&"'",conn,1,1 if not rs.eof then if rs("level1")="管理員" then session("admin")=1 if rs("level1")="版主" then session("admin")=2 if rs("level1")<>"版主" and rs("level1")<>"管理員" then session("admin")=0 else session("admin")=0 end if rs.close end if if not rs11("regshow") and session("useridname")="" then response.Redirect "error.asp?info=您尚未登錄,不能查看留言內容!" webname=rs11("webname") homepage=rs11("weblink") show=rs11("show") del=no type1=no del=request("del") type1=request("type1") if del="ok" and ((session("admin")=1) or (session("admin")=2)) then if type1="ok" then dsql="delete From reply where id1="&request("id") conn.execute(dsql) rs.open "Select * from guest where ID = " & request("ID1"),conn,2,3 rs("hf")=rs("hf")-1 rs1.open "Select * from reply where id="&rs("id")&" order by id1 desc",conn,1,1 if rs1.eof then rs("lastname")="——" rs("lastdate")=rs("lydate") else rs("lastname")=rs1("replyname") rs("lastdate")=rs1("replydate") end if rs.update rs1.close response.Redirect "show.asp?id="&request("id1") else rs.open "Select * from guest where ID = " & request("ID"),conn,2,3 dsql="delete from reply where id="&request("id") conn.execute(dsql) dsql="delete From guest where id="&request("id") conn.execute(dsql) response.Redirect "default.asp" end if set rs=nothing set rs1=nothing end if sh=no type1=no sh=request("sh") type1=request("type1") if sh="ok" and ((session("admin")=1) or (session("admin")=2)) then if type1="ok" then dsql="update reply set mark=1 where id1="&request("id1") conn.execute(dsql) else rs.open "Select * from guest where ID = " & request("ID"),conn,2,3 dsql="update guest set mark=1 where id="&request("id") conn.execute(dsql) if request("all")="1" then dsql="update reply set mark=1 where id="&request("id") conn.execute(dsql) end if end if set rs=nothing set rs1=nothing response.Redirect "show.asp?id="&request("id") end if if (request("act")<>"") and ((session("admin")=1) or (session("admin")=2)) then select case request("act") case 0 rs.open "Select count(*) as hfcount from reply where ID = " & request("ID"),conn,1,1 dsql="update guest set hf="&rs("hfcount")&" where id="&request("id") conn.execute(dsql) rs.close rs.open "Select * from guest where ID = " & request("ID"),conn,3,3 rs1.open "Select * from reply where id="&request("id")&" order by id1 desc",conn,1,1 if rs1.eof then rs("lastname")="——" rs("lastdate")=rs("lydate") else rs("lastname")=rs1("replyname") rs("lastdate")=rs1("replydate") end if rs.update rs.close rs1.close case 1 dsql="update guest set top1=1 where id="&request("id") conn.execute(dsql) case 2 dsql="update guest set top1=0 where id="&request("id") conn.execute(dsql) case 3 dsql="update guest set jinghua=1 where id="&request("id") conn.execute(dsql) case 4 dsql="update guest set jinghua=0 where id="&request("id") conn.execute(dsql) case 5 dsql="update guest set lock=1 where id="&request("id") conn.execute(dsql) case 6 dsql="update guest set lock=0 where id="&request("id") conn.execute(dsql) case 7 dsql="update guest set lastdate='"&now&"' where id="&request("id") conn.execute(dsql) end select end if ID1=request("id") up1="no" next1="no" up1=request("up") next1=request("next") if up1="ok" then rs.open "Select * from guest where ID < " & ID1,conn,3,3 if rs.recordcount=0 then rs.close rs.open "select * from guest where ID="&ID1,conn,3,3 end if rs.movelast rs1.open "Select * from reply where ID = " & rs("id")&" order by replydate",conn,3,3 end if if next1="ok" then rs.open "Select * from guest where ID > " & ID1,conn,3,3 if rs.recordcount=0 then rs.close rs.open "select * from guest where ID="&ID1,conn,3,3 end if rs1.open "Select * from reply where ID = " & rs("id")&" order by replydate",conn,3,3 end if if (up1<>"ok") and (next1<>"ok") then rs.open "Select * from guest where ID = " & ID1,conn,3,3 rs1.open "Select * from reply where ID = " & ID1&" order by replydate",conn,3,3 end if if (not rs("mark")) and show and ((session("admin")<>1) and (session("admin")<>2)) then response.Redirect("error.asp?info=本留言為未審核,不能查看!") rs("yd")=rs("yd")+1 rs.update Set rs4=server.createobject("ADODB.RECORDSET") rs4.open "Select * From option1" ,Conn,3,3 if rs1.recordcount<>0 then dim maxperpage,url,PageNo url="show.asp?id="&id1 rs1.pagesize=10 PageNo=REQUEST("PageNo") maxperpage=rs.pagesize if PageNo="" or PageNo=0 then PageNo=1 rs1.AbsolutePage=PageNo TSum=rs1.pagecount RowCount=rs1.PageSize PageNo=PageNo+1 PageNo=PageNo-1 else PageNo=1 TSum=1 end if %>
| |
default.asp<%else%>default1.asp<%end if%>">回留言列表 |
留言板方式查看
配色:
|
您是本留言第 <%=rs("yd")%> 個閱讀者 |
"> |
| * 留言主題:
<%if rs("subject")="" then %>
無標題
<%else%>
"><%=rs("subject")%>
<%end if%>
">
|
<%if not rs2.eof then%>
<%else%>
<% if not rs2.eof then %> 頭銜:<%=rs2("level1")%> 發言數:<%=rs2("count1")%> <%end if%> |
"" then%><%else%>class="tablebg<%=skin%>i"<%end if%>>
|
|||||
[本主題已被<%=rs("edituser")%>於<%=rs("edittime")%>編輯過] |
||||||
<%if not rs2.eof then%>
<%if rs2("mail")<>"" then%>
<%if ((session("admin")=1) or (session("admin")=2)) or (rs11("showmail")) then%>"> <%end if%>
<%end if%>
郵件
<%else%>
<%if rs("mail")<>"" then%>
<%if ((session("admin")=1) or (session("admin")=2)) or (rs11("showmail")) then%>"> <%end if%>
<%end if%>
郵件
<%end if%>
<%if not rs2.eof then%>
<%if rs2("qq")<>"" then%>
" target="_self">
<%end if%>
QQ
<%else%>
<%if rs("qq")<>"" then%>
" target="_self">
<%end if%>
QQ
<%end if%>
<%if (session("admin")=1) or (session("admin")=2) then response.write(rs("ip")) else response.write("IP")%> |
<%if (session("admin")=1) or (session("admin")=2) then%>
<%if (not rs("mark")) and show then%> ');">刪除
<%end if%>
<%if not rs("lock") then%>
">回復<%end if%>
<%end if%>
|
|||||
<% if not rs3.eof then %> 頭銜:<%=rs3("level1")%> 發言數:<%=rs3("count1")%> <% end if%> |
"" then%><%else%>class="tablebg<%=skin%>i"<%end if%>>
|
|||||
[本回復已被<%=rs1("edituser")%>於<%=rs1("edittime")%>編輯過] |
||||||
<%if left(rs1("replydate"),1)=0 then response.write "20"&rs1("replydate") else response.write rs1("replydate")%>
<%if not rs3.eof then%>
<%if rs3("mail")<>"" then%>
<%if ((session("admin")=1) or (session("admin")=2)) or (rs11("showmail")) then%>"><%end if%>
<%end if%>
郵件
<%else%>
<%if rs1("mail")<>"" then%>
<%if ((session("admin")=1) or (session("admin")=2)) or (rs11("showmail")) then%>"><%end if%>
<%end if%>
郵件
<%end if%>
<%if not rs3.eof then%>
<%if rs3("homepage")<>"" then%>
" target="_self">
<%end if%>
主頁
<%else%>
<%if rs1("homepage")<>"" then%>
" target="_self">
<%end if%>
主頁
<%end if%>
<%if not rs3.eof then%>
<%if rs3("qq")<>"" then%>
" target="_self">
<%end if%>
QQ
<%else%>
<%if rs1("qq")<>"" then%>
" target="_self">
<%end if%>
QQ
<%end if%>
<%if (session("admin")=1) or (session("admin")=2) then response.write(rs1("ip")) else response.write("IP")%> |
<%if (session("admin")=1) or (session("admin")=2) then%>
<%if (not rs1("mark")) and show then%> ','<%=rs1("id")%>');">刪除
<%end if%>
<%if not rs("lock") then%>
">回復<%end if%>
<%end if%>
|
|||||
|
<% call showpage(url,rs1.RECORDCOUNT,maxperpage,false,true,"條回復") %>
|
| <% %> |