<!-- #include file="setup.asp" -->
<%
id=int(Request("id"))
if id<>empty then Response.Cookies("forumid")=id
if ""&adminpassword&""=empty then response.redirect "install.asp"
top
if ""&nowdate&""<>""&date()&"" then
today=conn.execute("Select SUM(today) from bbsconfig")(0)
if ""&today&""="" then today=0
conn.execute("update [clubconfig] set today=0,oldday="&today&",Nowdate='"&date()&"'")
conn.execute("update [bbsconfig] set today=0")
conn.execute("update [user] set countupfiles=10")
end if
<!-----------------首页提示开始--------------->
if always=1 or (always=2 and request.Cookies("note")=empty)  then
%>
<style type="text/css">
#fadeinbox{position:absolute;width:350px;left:0;top:-400px;border:2px #4D76B3;background-color:#F3F6FA;padding:4px;z-index:100;visibility:hidden;}
</style>
<DIV id=fadeinbox style="filter:progid:DXImageTransform.Microsoft.RandomDissolve(duration=1) progid:DXImageTransform.Microsoft.Shadow(color=gray,direction=135) ; -moz-opacity:0">
<table border=0 width=350 cellspacing=2 cellpadding=4 class=a2>
<tr><td width=100% class=a4 align=center><font color=blue><B><%=clubname%>BBS社区 提示您：</B></font></td></tr>
<tr><td width=100% class=a4>
<table border=0 width=100%  cellspacing=0 cellpadding=0>
<tr><td width=100% align=center>
<script>document.write(ybbcode("<%=notecontent%>"))</script><BR></td></tr><tr><td align="right">
<span style=cursor:hand onClick="hidefadebox();return false">[关闭显示] </span>
</td></tr></table></td></tr></table></div>
<script defer src="inc/SuperNote.js"></script>
<%
response.Cookies("note")=1
end if
%>
<!-----------------首页提示结束--------------->
<SCRIPT>valigntop()</SCRIPT>

<table cellspacing="1" cellpadding="0" width="<%=dkuan%>"  align="center" border="0">
<td>
<table width="100%" border="0" cellpadding="2" cellspacing="1" class="a2">
<tr class="a1" height=26>
<td width="100%" colspan="4">
<tr class=a4>
<td height="25" align="center" width="6%" rowspan="2"> 
<embed src=images/Clock.swf width=80 height=80 wmode=transparent>
<SCRIPT language=JavaScript>
var enabled = 0; today = new Date();
var day; var date;
if(today.getDay()==0) day = "<br>星 期 日"
if(today.getDay()==1) day = "<br>星 期 一"
if(today.getDay()==2) day = "<br>星 期 二"
if(today.getDay()==3) day = "<br>星 期 三"
if(today.getDay()==4) day = "<br>星 期 四"
if(today.getDay()==5) day = "<br>星 期 五"
if(today.getDay()==6) day = "<br>星 期 六"
document.fgColor = "black";
date = "" + (today.getYear()) + "-" +
(today.getMonth() + 1 ) + "-" + today.getDate() + "" +
day +"";
document.write(date)
</SCRIPT>
</td></td>
<td align="center"> 
<%
if Request.Cookies("username") = empty then
%>
<form action="login.asp" method="post">
<input type="hidden" value="add" name="menu">
<input type="hidden" value="Default.asp" name="url">
<table border="0" width="97%">
	<tr><BR>
		<td align="center">用户名称:
<input size="15" name="username" value="<%=Request.Cookies("username")%>"></td>
		<td>

<input type="checkbox" value="1" name="eremite" id="eremite"><label for="eremite">隐身</label> 
		</td>
		<td align="center">

<input type="submit" value=" 登录 " name="Submit1"></td>
	</tr>
	<tr>
		<td align="center">

用户密码: <input type="password" size="15" value name="userpass"></td>
		<td> 

<input type="checkbox" value="1" name="xuansave" id="xuansave"><label for="xuansave">记忆</label>　
</td>
		<td align="center"> <input type="reset" value=" 取消 " name="Submit"></td>

<%if yanzhengma>0 then%>
	<tr>
	  <td align="center">用户验证:
	    <input size="15" name="addcode" value name="addcode">
	  </td>
	  <td><%=getcode1()%></td>
	  <td align="center"></td>
	  </tr><%end if%>
	</tr></form>
</table>
<%
else%>

<table border="0" width="97%">
	<tr>
		<td>&nbsp;::
		<a href="profile.asp">我的资料</a></td>
		<td>&nbsp;::
		<a onclick="javascript:open('message.asp?menu=post','','width=320,height=170')" href="#">发送短信</a></td>
		<td>&nbsp;::
		<a href="upface.asp">上传头像</a></td>
	</tr>
	<tr>
		<td>&nbsp;::
		<a href="ShowBBS.asp?menu=5">我的帖子</a></td>
		<td>&nbsp;::
		<a href="message.asp">我的留言</a></td>
		<td>&nbsp;::
		<a href="upphoto.asp">上传照片</a></td>
	</tr>
	<tr>
		<td>&nbsp;::
		<span style="text-decoration: none"><a href="calendar.asp">我的日记</a></span></td>
		<td>&nbsp;::
		<a href="friend.asp">我的好友</a></td>
		<td>&nbsp;::
		<span style="text-decoration: none"><a href="favorites.asp">我的收藏</a></span></td>
	</tr>
</table>


<%
end if
%>
	</td>
	<td> 

<table border="0" width="97%">
	<tr><td colspan="2">论坛坛主: 
      <%

sql="select * from [user] where membercode > 5 order by membercode Desc,landtime Desc"
rs.Open sql,Conn,1 
i=0
Do While Not RS.EOF
i=i+1
%>
      <%if i>1 then%>|<% end if %>
      <a href=Profile.asp?username=<%=rs("username")%>><b><%=rs("username")%></b></a> 
      <%
RS.MoveNext
loop
RS.Close

%>
    </td></tr>	<tr>
		<td>注册会员:<b><%=Application(CacheName&"CountUser")%></b></td>
		<td><%
newusername=Conn.Execute("Select username From [USER] order by ID Desc")(0)
response.write "新进会员:<b><a href=Profile.asp?username="&newusername&">"&newusername&"</a></b>"
%></td>
	</tr>
	<tr>
		<td>主题总数:<b><%=Application(CacheName&"CountForum")%></b></td>
		<td>回帖总数:<b><%=Application(CacheName&"CountReforum")%></b></td>
	</tr>
	<tr>
		<td>今日帖数:<b><font color=red><%=today%></font></b></td>
		<td>昨日帖数:<b><%=oldday%></b></td>
	</tr>
	</table>

</td>
</tr>
<tr class=a4><td height="12" align="center" width="78%" colspan="2"> 
  | <a href="ShowBBS.asp?menu=2">本周热门帖子</a> 
  | <a href="ShowBBS.asp?menu=1">本周人气帖子</a>
  | <a href="ShowBBS.asp">社区新帖</a>  
  | <a href="ShowBBS.asp?menu=3">精华帖子</a>  
  | <a href="ShowBBS.asp?menu=4">投票帖子</a>
  | <a href="userlist.asp?menu=5">社区排行</a>
  | <a href="markettop.asp?menu=6">文章上市</a>
  | <a href="bzsq-sq.asp?menu=7">申请版主</a>
  | <a href="vip.asp?menu=8">VIP申请</a>
</table>

<td width="25%" valign="top">
<table width="100%" border="0" cellpadding="5" cellspacing="1" class="a2">
<tr class="a1" id="TableTitleLink">
<td height="15" align="Left" valign="middle">&nbsp;<a href="Affiche.asp">社区公告</a></td>
</tr>
<tr class="a4">
<td height="114" align="Left" valign="top">
<table border="0" width="100%">
<%
Set Rs=Conn.ExeCute("Select top 5 * From [Affiche] Order By ID Desc")
Do While Not Rs.Eof
title=Rs("title")
if len(title)>17 then title=Left(""&title&"",14)&"..."
%>
<tr>
<td><a href="Affiche.asp?ID=<%=Rs("ID")%>"><%=title%></a></td>
</tr>
<%
Rs.MoveNext
Loop
Rs.Close
%>
</table>
</td>
</tr>
</table>
</td>

<!----本周代码开始--->
<%if benzu=1 then%>
<!-- #include file="tcfb.asp" -->
<%end if%>
<!---本周代码开始--->

<table width="<%=dkuan%>" align="center" border="0" class="a2" cellspacing=1 cellpadding=0>
<br>
<%
if Request.Cookies("forumid")<>empty then
sql="select * from bbsconfig where id="&int(Request.Cookies("forumid"))&""
Set Rs=Conn.Execute(sql)
if Rs.eof then Response.Cookies("forumid")=""
if ""&Rs("password")&""="" then:password=0:else:password=1:end if
%><script>ShowList("<%=Rs("pass")%>","<%=Rs("id")%>","<%=Rs("bbsname")%>","<%=Rs("icon")%>","<%=Rs("intro")%>","<%=Rs("moderated")%>","<%=Rs("today")%>","<%=Rs("toltopic")%>","<%=Rs("tolrestore")%>","<%=Rs("lasttime")%>","<%=Rs("lastname")%>","<%=Rs("lasttopic")%>","<%=password%>");</script><%
rs.close
else
ForumList(0)
end if
%>
</table>

<SCRIPT>valignbottom()</SCRIPT>
<!----明星代码开始--->
<br>
<%if mingx=1 then %>
<!-- #include file="tcmx.asp" -->
<!--#include file="mingxing.asp"-->
<br>
<% end if%>
<!----明星代码结束--->
<!----社区聊天代码开始--->
<%if fabiao=1 then%>
<!-- #include file="cfchat.asp" -->
<br>
<%end if%>
<!----社区聊天代码结束--->

<SCRIPT>valigntop()</SCRIPT>
<table cellspacing="1" cellpadding="1" width="<%=dkuan%>" align="center" border="0" class="a2"><tr><td height="25" class="a1" colspan="2">&nbsp;<b><font color="#ffffff">您的个人状态</font></b></td></tr><tr>

		<td align="middle" width="6%" class=a3><img src="images/mystate.gif"></td><td class="a4"><table cellspacing="0" cellpadding="3" width="97%" border="0" style="border-left: 0px none; border-top: 0px none; border-bottom: 1px none"><tr><td><table border="0" cellpadding="0" cellspacing="0" width="97%"><%
if Request.Cookies("username") <> "" then

sql="select * from [user] where username='"&Request.Cookies("username")&"'"
Set Rs=Conn.Execute(sql)


%> <tr><td width="25%"><%=rs("username")%> - 有 <font face="Georgia, Times New Roman, Times, serif"><%=rs("newmessage")%> 条新留言</font></td><td width="20%">
				体力：<font face="Georgia, Times New Roman, Times, serif"><%=rs("userlife")%></font></td><td width="20%">
				社区金币：<font face="Georgia, Times New Roman, Times, serif"><%=rs("money")%></font></td><td width="17%">发表文章：<font face="Georgia, Times New Roman, Times, serif"><%=rs("posttopic")%></font></td><td width="18%">被删文章：<font face="Georgia, Times New Roman, Times, serif"><%=rs("deltopic")%></font></td></tr><tr><td>等级名称：<Script>document.write(level(<%=rs("experience")%>,<%=rs("membercode")%>,'','')+levelname);</Script></td><td>
						经验：<font face="Georgia, Times New Roman, Times, serif"><%=rs("experience")%></font></td><td>
				社区存款：<font face="Georgia, Times New Roman, Times, serif"><%=rs("savemoney")%></font></td><td>回复文章：<font face="Georgia, Times New Roman, Times, serif"><%=rs("postrevert")%></font></td><td>精华文章：<font face="Georgia, Times New Roman, Times, serif"><%=rs("goodtopic")%> </font></td></tr><%
rs.close
end if
bbsname=clubname
forumid=0

%> <!-- #include file="inc/line.asp" --><tr><td>
<script>
temp=navigator.appVersion
temp=temp.replace(")","");
temp=temp.replace("MSIE","Internet Explorer");
temp=temp.replace("NT 5.0","2000");
temp=temp.replace("NT 5.1","XP");
temp=temp.replace("NT 5.2","2003");
var appVersion= temp.split ('; '); 
</script>
您的ＩＰ：<font face="Georgia, Times New Roman, Times, serif"><%=Request.ServerVariables("REMOTE_ADDR")%></font></td><td>端口：<font face="Georgia, Times New Roman, Times, serif"><%=Request.ServerVariables("REMOTE_PORT")%></font></td><td>操作系统：<script>document.write(appVersion[2])</script></td><td colspan="2">浏览器：<script>document.write(appVersion[1])</script></td></tr></table></td></tr></table></td></tr></table><%
regonline=conn.execute("Select count(sessionid)from online where username<>''")(0)

if Application(CacheName&"BestOnline")<onlinemany then
Application(CacheName&"BestOnline")=onlinemany
Application(CacheName&"BestOnlineTime")=now()
end if
%>

<SCRIPT>valignbottom()</SCRIPT>
<br>
<SCRIPT>valigntop()</SCRIPT>
<table cellspacing="1" cellpadding="5" width="<%=dkuan%>" border="0" class="a2" align="center"><tr><td height="25" colspan="2" class="a1">&nbsp;<b><font color="#ffffff">友情链接</font></b>　　<b>[<a onclick="javascript:open('link.asp','','width=400,height=260')" href="#">申请链接</a>]</b></td></tr><tr>
<td align="center" class=a3 width="6%" rowspan="2"><img src="images/shareforum.gif"></td>
<td class="a4"><%
sql="select * from [link] where shenhe='1'"
rs.Open sql,Conn
do while not rs.eof
if rs("logo")="" or rs("logo")="http://" then
link1=link1+"<a title='"&rs("intro")&"' href="&rs("url")&" target=_blank>"&rs("name")&"</a> "
else
link2=link2+"<a title='"&rs("name")&""&chr(10)&""&rs("intro")&"' href="&rs("url")&" target=_blank><img src="&rs("logo")&" border=0 width=88 height=31></a> "
end if
rs.movenext
loop
rs.close
%>
<%=link1%>
</td></tr><tr>
<td class="a4" width="99%"><%=link2%></td></table>

<SCRIPT>valignbottom()</SCRIPT>
<br>
<table cellspacing="1" cellpadding="0" width="<%=dkuan%>" align="center" border="0" class="a2"><tr><td height="25" class="a1" colspan="2">&nbsp;<b><font color="#ffffff">统计信息</font></b></td></tr><tr><td align="middle" width="6%" class=a3><img src="images/totel.gif">&nbsp;</td><td valign="top" class="a4"><table cellspacing="0" cellpadding="3" width="97%"><td height="15">&nbsp;<SCRIPT>
hour=new Date().getHours()
if(hour < 6){document.write("凌晨了,早上不用上班吗?")}
else if (hour < 8){document.write("早上了,全新的一天!")}
else if (hour < 12){document.write("上午好,在工作吗?")}
else if (hour < 13){document.write("中午好,该吃饭了!外面太阳大吗？")}
else if (hour < 14){document.write("午安!,不打盹吗?")}
else if (hour < 18){document.write("下午好,下午工作愉快啊!")}
else if (hour < 19){document.write("傍晚好,吃晚饭了吗?")}
else if (hour < 22){document.write("晚上好,没有别的事吗?")}
else if (hour < 24){document.write("夜深了! 要注意身体呀! 祝你做个好梦!")}
</script>
<tr><td height="15">&nbsp;从&nbsp;<font color=FF0000><%=stime%></font>&nbsp;建站,论坛经历了&nbsp;<font color=FF0000><%=date-cdate(stime)%></font>&nbsp;天。
<%
online=conn.execute("Select count(*)from online")(0)
sql="select * from clubconfig where clubname<>''"
rs.Open sql,Conn,1,3
if online>rs("toponline") then
rs("toponline")=online
rs("toponlinetime")=now
rs.update
end if
%>
<tr><td height="15">&nbsp;历史最高在线记录&nbsp;<b><font color="#FF0000"><%=rs("toponline")%></font></b>&nbsp;人，发生在&nbsp;<font color="#FF0000"><%=rs("toponlinetime")%></font>。<%
rs.close
%>
<tr><td height="15">&nbsp;<img loaded="no" src="images/plus.gif" id="followImg0" style="cursor:hand;" onclick="loadThreadFollow(0,<%=forumid%>)">目前论坛总共有 <b><%=onlinemany%></b> 人在线。其中注册用户 <b><%=regonline%></b> 人，访客 <b><%=onlinemany-regonline%></b> 
	人。近日最高在线 <font color=red><b><%=Application(CacheName&"BestOnline")%></b></font> 人，发生在 <b><%=Application(CacheName&"BestOnlineTime")%></b> 
	</td></tr><tr height="25" style="display:none" id="follow0"><td id="followTd0" align="left" class="a4" width="94%" colspan="5">
		　Loading.....</td></tr></table>&nbsp;&nbsp;◇&nbsp;<font color=red>名单图例</font>：<img src=images/membercode/6.gif border=0>  社区区长 <img src=images/membercode/5.gif border=0>  管理员 <img src=images/membercode/4.gif border=0>  超级版主 ‖<img src=images/membercode/3.gif border=0>  版主 ‖<img src=images/membercode/2.gif border=0> VIP会员 ‖<img src=images/membercode/1.gif border=0>  会员 ‖<img src=images/membercode/0.gif border=0>  访客或隐身</table>

<SCRIPT>valignbottom()</SCRIPT>
<br>
<SCRIPT>valigntop()</SCRIPT>
<br>
<center>&nbsp;<img src=images/skins/<%=Request.Cookies("skins")%>/Board0.gif alt="禁止浏览">&nbsp;关闭论坛&nbsp;&nbsp;<img src=images/skins/<%=Request.Cookies("skins")%>/Board1.gif alt="任何人均可浏览">&nbsp;正规论坛&nbsp;&nbsp;<img src=images/skins/<%=Request.Cookies("skins")%>/Board2.gif alt="游客禁止浏览">&nbsp;会员论坛&nbsp;&nbsp;<img src=images/skins/<%=Request.Cookies("skins")%>/Board3.gif alt="需要授权才能浏览">&nbsp;私密论坛<br>

<% if fdimg<>"" then %>
<DIV id=img style="LEFT: 100px; WIDTH: 177px; POSITION: absolute; TOP: 124px; HEIGHT: 56px">              
<TABLE cellSpacing=0 cellPadding=0 border=0>                
  <TBODY>                
  <TR>                
    <TD vAlign=center>                
      <SCRIPT language=JavaScript>                  
      <!-- Begin                  
      var xPos=20;                  
      var yPos=document.body.clientHeight;                  
      var step=1;var delay=40;var height=0;                  
      var Hoffset=0;                  
      var Woffset=0;                  
      var yon=0;                  
      var xon=0;                  
      var pause=true;                  
      var interval;                  
      img.style.top=yPos;                  
      function changePos(){width=document.body.clientWidth;height=document.body.clientHeight;Hoffset=img.offsetHeight;Woffset=img.offsetWidth;img.style.left=xPos+document.body.scrollLeft;img.style.top=yPos+document.body.scrollTop;if(yon){yPos=yPos+step;}else{yPos=yPos-step;}if(yPos<0){yon=1;yPos=0;}if(yPos>=(height-Hoffset)){yon=0;yPos=(height-Hoffset);}if(xon){xPos=xPos+step;}else{xPos=xPos-step;}if(xPos<0){xon=1;xPos=0;}if(xPos>=(width-Woffset)){xon=0;xPos=(width-Woffset);}}function start(){img.visibility="visible";interval=setInterval('changePos()',delay);}start();//-->                  
      </SCRIPT>                
          <a target=_blank href=<%=fdurl%>><img border="0" src="<%=fdimg%>"></a>             
          <DIV align=center></DIV></TD></TR></TBODY></TABLE></DIV>
<%end if%>
<%
htmlend

sub ForumList(selec)

sql="Select * From bbsconfig where followid="&selec&" and hide=0 order by SortNum"
Set Rs1=Conn.Execute(sql)
do while not Rs1.eof
if selec=0 then ListStyle=rs1("ListStyle")
if ii=0 then
%>

<table width="<%=dkuan%>" align="center" border="0" class="a2" cellspacing=1 cellpadding=0>
<tr class=a1 id=TableTitleLink><td colspan=7 height=25 title='<%=Rs1("intro")%>'><b>　<a href=ShowForum.asp?forumid=<%=Rs1("id")%>><%=Rs1("bbsname")%></a></b></td></tr>
<%
else
if ""&Rs1("password")&""="" then:password=0:else:password=1:end if

if ListStyle=0 then
%><script>SmallShowList("<%=Rs1("id")%>","<%=Rs1("bbsname")%>","<%=Rs1("intro")%>","<%=Rs1("moderated")%>","<%=Rs1("today")%>","<%=Rs1("toltopic")%>","<%=Rs1("tolrestore")%>");</script><%
else
%><script>ShowList("<%=Rs1("pass")%>","<%=Rs1("id")%>","<%=Rs1("bbsname")%>","<%=Rs1("icon")%>","<%=Rs1("intro")%>","<%=Rs1("moderated")%>","<%=Rs1("today")%>","<%=Rs1("toltopic")%>","<%=Rs1("tolrestore")%>","<%=Rs1("lasttime")%>","<%=Rs1("lastname")%>","<%=Rs1("lasttopic")%>","<%=password%>");</script><%
end if

end if

ii=ii+1
if ii < int(floor) then ForumList Rs1("id")
ii=ii-1

Rs1.movenext
loop
Set Rs1 = Nothing
if ListStyle=0 then
%><script>makeupShowList();</script><%
end if

end sub
Function getcode1()
	Dim test
	On Error Resume Next
	Set test=Server.CreateObject("Adodb.Stream")
	Set test=Nothing
	If Err Then
		Dim zNum
		Randomize timer
		zNum = cint(8999*Rnd+1000)
		Session("GetCode") = zNum
		getcode1= Session("GetCode")		
	Else
		getcode1= "<img src=""nccode.asp"">"		
	End If
End Function

%>

