<%@ codepage="936" %> <%@ Language=VBScript%> <% Response.Buffer=true Response.Expires=0 %> <% keyno=Request.QueryString("keyno") classcode=Request.QueryString("classcode") pageno=Request.QueryString("pageno") set cn = Server.CreateObject("ADODB.Connection") cn.Open(mycnstr) set rs = Server.CreateObject("ADODB.Recordset") set rs2 = Server.CreateObject("ADODB.Recordset") if classcode<>"" then sql="select * from forum_class where state='1' and classcode='"+classcode+"'" else sql="select * from forum_class where state='1' order by sortnum" end if rs2.Open sql,cn,1,1 if not rs2.EOF then manager=trim(rs2("manager")) classcode=trim(rs2("classcode")) classname=trim(rs2("classname")) topcount=rs2("topcount") totcount=rs2("reccount") flag=rs2("flag") else Response.End end if rs2.Close select case Session("userflag") case "1" userqx=mid(flag,2,1) case "2" userqx=mid(flag,3,1) case else userqx=mid(flag,1,1) end select if manager<>"" then keyword=manager+"/" manager="" xx1=1 xx2=instr(xx1,keyword,chr(47)) wheretxt="" do while xx2>0 ttt=mid(keyword,xx1,xx2-xx1) if ttt<>"" then sql="select userno from userinfo where state='1' and usercode='"+ttt+"'" rs2.Open sql,cn,1,1 if not rs2.EOF then if cstr(Session("userno"))=cstr(rs2(0)) then userqx="9" end if ttt=""+ttt+"" if manager="" then manager=ttt else manager=manager+","+ttt end if end if rs2.Close end if xx1=xx2+1 xx2=instr(xx1,keyword,"/") loop else manager="暂无" end if if Session("userqx")="9" or Session("userflag")="9" then userqx="9" end if if userqx="0" then Response.End end if if Request.ServerVariables("REQUEST_METHOD")="POST" and userqx="9" then rectot=Request.Form("rectot") cn.BeginTrans for i=1 to rectot checksele=Request.Form("checksele"&i) if checksele<>"" then seleitem=Request.Form("seleitem"&i) sqltext="delete from forum where parentno="&seleitem cn.Execute sqltext end if next sql="select count(keyno) from forum where classcode='"+classcode+"' and grade=1" rs2.Open sql,cn,1,1 topcount=rs2(0) rs2.Close sql="select count(keyno) from forum where classcode='"+classcode+"'" rs2.Open sql,cn,1,1 reccount=rs2(0) rs2.Close sql="update forum_class set topcount="&topcount&",reccount="&reccount&" where classcode='"+classcode+"'" cn.Execute sql cn.CommitTrans end if myurl="forum_list.asp?classcode="+classcode mymenu="forum" sql="select * from forum where classcode='"+classcode+"' and grade=1 order by topflag desc,replyno desc" rs.Open sql,cn,1,1 pagesize=25 rs.PageSize=pagesize if pageno="" then pageno=1 else pageno=cint(pageno) if rs.PageCount>0 then rs.AbsolutePage=pageno pagecount=rs.PageCount reccount=rs.RecordCount %> <% mybz=0 set rsb1 = Server.CreateObject("ADODB.Recordset") set rsb2 = Server.CreateObject("ADODB.Recordset") if Session("userno")="" then c_usercode=Request.Cookies("usercode") c_userpass=Request.Cookies("userpass") c_loginflag=Request.Cookies("loginflag") if c_usercode<>"" then sql="select userno,userpass,flag,state,logintime,logincount,picfile,ipaddress from userinfo where usercode='"+c_usercode+"' and state='1'" rsb1.Open sql,cn,1,3 if rsb1.EOF then else oldpass=Lcase(trim(rsb1(1))) if oldpass=c_userpass then mybz=1 rsb1("logintime")=now() rsb1("logincount")=rsb1("logincount")+1 rsb1("ipaddress")=Request.ServerVariables("Remote_HOST") rsb1.Update Session("userno")=rsb1(0) Session("usercode")=c_usercode Session("userflag")=c_loginflag userno=rsb1(0) cn.Execute "delete from user_login where userno="&userno&" or keyno="&Session.SessionID if databaseflag="access" then sql="Insert into user_login values ("&Session.SessionID&","&userno&",'"+c_usercode+"',now(),now(),'"+classcode+"','"+loginflag+"','"+Request.ServerVariables("Remote_HOST")+"')" else sql="Insert into user_login values ("&Session.SessionID&","&userno&",'"+c_usercode+"',getdate(),getdate(),'"+classcode+"','"+loginflag+"','"+Request.ServerVariables("Remote_HOST")+"')" end if cn.Execute sql end if end if rsb1.Close end if end if if mybz=0 then sql="select * from user_login where keyno="&Session.SessionID rsb2.Open sql,cn,1,3 if not rsb2.EOF then rsb2("updatetime")=now() rsb2("classcode")=classcode else rsb2.Addnew rsb2("keyno")=Session.SessionID rsb2("userno")=0 rsb2("logintime")=now() rsb2("updatetime")=now() rsb2("loginflag")="0" rsb2("ipaddress")=Request.ServerVariables("Remote_HOST") rsb2("classcode")=classcode end if rsb2.Update rsb2.Close end if %> <%=classname%>_<%=forumtitle%>_澳大利亚ABC环球集团
<%if Session("userno")<>"" then%> <%else%> <%end if%>
<%=Session("usercode")%> 重登录 | 注销 | 我的资料 | 现在时间是 <%=time()%>  
登录 | 注册 | 现在时间是 <%=time()%>  
<% sql="select count(keyno) from user_login" rs2.Open sql,cn,1,1 reccount1=rs2(0) rs2.Close sql="select count(keyno) from user_login where classcode='"+classcode+"'" rs2.Open sql,cn,1,1 reccount2=rs2(0) rs2.Close %>
  欢迎光临<%=forumtitle%>  
<%if classflag="1" then%> <%else%> <%end if%>
<%=forumtitle%> > <%=classname%> > 帖子列表<%=forumtitle%> > <%=classname%> > 帖子列表<% select case Session("userflag") case "1" '内部用户 if databaseflag="access" then sql="select * from forum_class where state='1' and mid(flag,2,1)>'0' order by sortnum " else sql="select * from forum_class where state='1' and substring(flag,2,1)>'0' order by sortnum " end if case "2" '高级用户 if databaseflag="access" then sql="select * from forum_class where state='1' and mid(flag,3,1)>'0' order by sortnum " else sql="select * from forum_class where state='1' and substring(flag,3,1)>'0' order by sortnum " end if case else if databaseflag="access" then sql="select * from forum_class where state='1' and mid(flag,1,1)>'0' order by sortnum " else sql="select * from forum_class where state='1' and substring(flag,1,1)>'0' order by sortnum " end if end select if userqx="9" then '管理员或总坛主 sql="select * from forum_class where state='1' order by sortnum " end if %>  
 目前共有 <%=reccount1%> 人在线,本版块有 <%=reccount2%> 人    主题帖: <%=topcount%> 总帖数: <%=totcount%>
<%else%> <%end if%>
<%if userqx="2" then%> 您对本版块具有只读权限 版主:<%=manager%>
<%if userqx="9" then%> <%end if%>
管理 帖子主题 作者 回复/人气 最后更新 | 回复人
<% i=1 do while not rs.EOF and i<=pagesize if i mod 2=1 then color1="FEFAF7" else color1="ffffff" end if %> <%if userqx="9" then%> <%end if%> <% i=i+1 rs.MoveNext loop rs.Close %>
"> ')"><%=rs("keyno")%> <% select case rs("topflag") case "2" Response.Write ("") case "1" Response.Write ("") case else Response.Write ("") end select %>
.gif" border="0"> " <% select case rs("topflag") case "2" Response.Write ("class=a03") case "1" Response.Write ("class=a02") case else Response.Write ("class=a01") end select %> target=_blank><%=Server.HTMLEncode(trim(rs("title")))%> <% if rs("flag")="1" then Response.Write ("") elseif rs("flag")="2" then Response.Write ("") end if %>  
" target=_blank><%=subss(trim(rs("usercode")),12)%> <%=rs("replycount")%>/<%=rs("querycount")%> <%if rs("replyno")>0 then%> " class="a01"><%=rs("replytime")%>|<%=subss(trim(rs("replyuser")),12)%> <%end if%>
 
  <%if userqx="9" then%> 全选 <%end if%> 页  共<%=pagecount%>页<%=reccount%>帖 
 
 用户访问情况
 您的真实IP:<%=Request.ServerVariables("Remote_HOST")%>  操作系统:<%=Request.ServerVariables("Http_User_Agent")%>
 在线用户情况
<% sql="select count(keyno) from user_login where loginflag='1'" rs.Open sql,cn,1,1 reccount2=rs(0) rs.Close sql="select * from user_login order by logintime " rs.Open sql,cn,1,1 colzs=8 if rs.RecordCount mod colzs=0 then rowzs=int(rs.RecordCount/colzs) else rowzs=int(rs.RecordCount/colzs)+1 end if reccount=rs.RecordCount %>
 目前共有 <%=reccount%> 人在线,其中注册用户 <%=reccount2%> 人,访客 <%=reccount-reccount2%>
<% for i=1 to rowzs Response.Write ("") for j=1 to colzs if not rs.EOF then %> <% rs.MoveNext else Response.Write("") end if next Response.Write ("") next %>
   <%if rs("loginflag")="1" then%> " target=_blank><%=trim(rs("usercode"))%> <%else%> ">[游客] <%end if%>  
<% if userqx="9" then %> <%end if%>