<%template _header%>
<!--foruminfo-->
<div id="foruminfo">
	<div class="userinfo">
		<h2><a id="NavHome" href="{config.forumurl}" 
		<%if {config.forumjump}==1%>
		onmouseover="showMenu(this.id);" onmouseout="showMenu(this.id);"
		<%/if%>>{config.forumtitle}</a></h2>
		<p>主题:<em>{totaltopic}</em>篇 　帖子:<em>{totalpost}</em>个 　今日帖子:<em>{todayposts}</em>个</p>
	</div>
	<div class="forumstats">
		<div id="search">
			<%if {usergroupinfo.allowsearch}>0%>
				 <%template _quicksearch%>
			<%/if%>
		</div>
		<ul>
		<%if {config.enablespace}==1%>
			<%if {isactivespace}%>
			<li><a href="{spaceurl}space">个人空间</a></li>
			<%else if {isallowapply}%>
			<li><a href="spaceregister.aspx">申请个人空间</a></li>
			<%/if%>
		<%/if%>
			<li><a href="showtopiclist.aspx?type=newtopic&amp;newtopic={newtopicminute}&amp;forums=all">查看新帖</a></li>
			<li><a href="showtopiclist.aspx?type=digest&amp;forums=all">精华帖区</a></li>
		<%if {config.rssstatus}!=0%>	
			<li class="lastitem"><a href="tools/rss.aspx" target="_blank"><img src="templates/{templatepath}/images/rss.gif" alt="rss"/></a></li>
		<%/if%>
		</ul>
	</div>
</div>
<!--foruminfo-->

<%if {announcementcount}>0%>
<!--announcement-->
<div id="announcement">
	<div id="announcementbody">
		<strong>公告:</strong>
		<marquee width="92%" direction="left" scrollamount="2" scrolldelay="1" onmouseover="this.stop();" onmouseout="this.start();">
		<ul>
			<%loop announcement announcementlist%>
			<li class="fontfamily">{announcement[starttime]}<a href="announcement.aspx#{announcement[id]}">{announcement[title]}</a></li>
			<%/loop%>
		</ul>
		</marquee>
	</div>
</div>
<!--announcement-->
<%/if%>

<%template _pagewordadlist%>
<%template _newpmmsgbox%>

<!--forumtopic-->
<%set (int){lastforumlayer} = -1%>
<%set (int){lastcolcount} = 1%>
<%set (int){lastforumid} = 0%>
<%set (int){subforumcount} = 0%>
<%loop (IndexPageForumInfo) forum forumlist%>
	<%if {forum.layer}==0%>
		<%if {lastforumlayer}>-1%>
			<%if {lastcolcount}!=1%>
						<%if {subforumcount}!=0%>
		</tr>
						<%/if%>
		</table>
	</div>
</div>
			<%else%>
			</table>
		</div>
	</div>			
			<%/if%>
<div id="ad_intercat_{lastforumid}"></div>
		<%/if%>
		<%if {forum.colcount}==1%>
<div class="ntforumbox forumtopic">
	<div class="titlebar">
		<span class="open">
		<%if {forum.moderators}!=""%>
			分类版主: {forum.moderators}
		<%/if%><a href="###" onclick="toggle_collapse('category_{forum.fid}');" class="opentopic"><img id="category_{forum.fid}_img"  src="templates/{templatepath}/images/open_no.gif" alt="展开/收起" /></a>
		</span>
		<h2>
		<%set {aspxrewriteurl} = this.ShowForumAspxRewrite({forum.fid},0)%>
		<a href="{aspxrewriteurl}">{forum.name}</a>
		</h2>
	</div>
	<div id="category_{forum.fid}">
	<table cellpadding="0" cellspacing="0" border="0">
	<thead>
		<tr>
			<th class="topicicon">&nbsp;</th>
			<th class="topictitle viewnumbers">论坛</th>
			<th class="ntnumbers">主题</th>
			<th class="ntnumbers">帖子</th>
			<th class="lastposter viewnumbers">最后发布</th>
		</tr>
	</thead>
	<%else%>
<div class="ntforumbox forumtopic">
	<div class="titlebar">
		<span class="open">
		<%if {forum.moderators}!=""%>
			分类版主: {forum.moderators}
		<%/if%><a href="###" onclick="toggle_collapse('category_{forum.fid}');" class="opentopic"><img id= "category_{forum.fid}_img" src="templates/{templatepath}/images/open_no.gif" alt="展开/收起" /></a>
		</span>
		<h2>
			<%set {aspxrewriteurl} = this.ShowForumAspxRewrite({forum.fid},0)%>
			<a href="{aspxrewriteurl}">{forum.name}</a>					
		</h2>
	</div>
	<div id="category_{forum.fid}">
		<table cellpadding="0" cellspacing="0" border="0" width="100%">								
		<%/if%>
		<%set {lastforumlayer}=0%>
		<%set {lastcolcount}={forum.colcount}%>
		<%set {lastforumid}={forum.fid}%>
		<%else%>
		<%if {forum.colcount}==1%>	
		<tbody>
		<tr class="list" onmouseover="this.className='liston'" onmouseout="this.className='list'">
			<td class="topicicon">
			<%set {aspxrewriteurl} = this.ShowTopicAspxRewrite({forum.lasttid},0)%>
			<a href="{aspxrewriteurl}" target="_blank"><img src="templates/{templatepath}/images/forum_{forum.havenew}.gif" border="0" alt="图例"/></a></td>
			<%set {aspxrewriteurl} = this.ShowForumAspxRewrite({forum.fid},0)%>
			<th class="topictitle" ondblclick="<%if {forum.redirect}==""%>window.location.href='{aspxrewriteurl}';<%else%>window.open('{forum.redirect}');<%/if%>">
					<%if {forum.icon}!=""%>
						<img src="{forum.icon}" border="0" align="left" hspace="5" alt="图例"/>
					<%/if%>
				<h3>
					<%if {forum.redirect}==""%>
						<%set {aspxrewriteurl} = this.ShowForumAspxRewrite({forum.fid},0)%>
						<a href="{aspxrewriteurl}">
					<%else%>
						<a href="{forum.redirect}" target="_blank">
					<%/if%>
					{forum.name}</a><%if {forum.todayposts}>0%><span class="today">({forum.todayposts})</span><%/if%>
				</h3>
				<p>{forum.description}</p>
				<p class="topicmanager"><span>版主:</span><%if {forum.moderators}!=""%>{forum.moderators}<%else%>空缺<%/if%></p>
			</th>
			<td class="ntnumbers">{forum.topics}</td>
			<td class="ntnumbers">{forum.posts}</td>
			<td class="lastposter">
			<%if {forum.status}==-1%>
				私密论坛
			<%else%>
				<%if {forum.lasttid}!=0%>
					<h4>
					   <%set {aspxrewriteurl} = this.ShowTopicAspxRewrite({forum.lasttid},0)%>
						<a href="{aspxrewriteurl}">{forum.lasttitle}</a>
					</h4>
					<div class="topicbackwriter">
						<%if {forum.lastposter}!=""%>
							<%if {forum.lastposterid}==-1%>
								游客
							<%else%>
							   <%set {aspxrewriteurl} = this.UserInfoAspxRewrite({forum.lastposterid})%>
								<a href="{aspxrewriteurl}" target="_blank">{forum.lastposter}</a>
							<%/if%>
						<%else%>
							匿名
						<%/if%>
						<%set {aspxrewriteurl} = this.ShowTopicAspxRewrite({forum.lasttid},0)%>
						(<a href="{aspxrewriteurl}" title="{forum.lasttitle}"><span><script type="text/javascript">document.write(convertdate('{forum.lastpost}'));</script></span></a>)
					</div>
				<%else%>
					从未
				<%/if%>
			<%/if%>
		  </td>
	   </tr>
	   </tbody>
	<%else%>
	<%set {subforumcount}={subforumcount}+1%>
	<%set (double){colwidth} = 99.9 / {forum.colcount} %>
<%if {subforumcount}==1%>
		<tr class="list" onmouseover="this.className='liston'" onmouseout="this.className='list'">
<%/if%>
			<td style="width:{colwidth}%;" class="hlist">
				<h4>
				<%if {forum.icon}!=""%>
					<img src="{forum.icon}" border="0" align="left" hspace="5" alt="图例"/>
				<%/if%>
				<%if {forum.redirect}==""%>
				   <%set {aspxrewriteurl} = this.ShowForumAspxRewrite({forum.fid},0)%>
					<a href="{aspxrewriteurl}">
				<%else%>
					<a href="{forum.redirect}" target="_blank">
				<%/if%>
				{forum.name}</a>
				</h4>
				<p>主题:<strong>{forum.topics}</strong> 今日发帖:<strong>{forum.todayposts}</strong></p>
				<p class="topicmanager">版主:<%if {forum.moderators}!=""%>{forum.moderators}<%else%>空缺<%/if%></p>
			</td>
<%if {subforumcount}=={forum.colcount}%>
		</tr>
	<%set {subforumcount}=0%>
<%/if%>
<%/if%>
	<%set {lastforumlayer}=1%>
	<%set {lastcolcount}={forum.colcount}%>
<%/if%>
<%/loop%>
<%if {lastcolcount}!=1%>
<%if {subforumcount}!=0%>
		</tr>
<%/if%>
	</table>
</div>
</div>
<%else%>
	</table>
</div>
</div>
<%/if%>
<!--forumtopic-->

<%if {forumlinkcount}>0%>
<div class="ntforumbox forumlink">
	<span class="open"><a href="###" onclick="toggle_collapse('linklist');" class="opentopic"><img id ="linklist_img" src="templates/{templatepath}/images/open_no.gif" alt="展开/收起" /></a></span>
	<h4>友情链接</h4>
	<div id="linklist">
		<table cellpadding="0" cellspacing="0" border="0">
		<%loop forumlink forumlinklist%>
			<%if {forumlink[logo]}!=""%>
			<tbody>	
				<tr class="list" >
					<td  class="topicicon">
						<img src="templates/{templatepath}/images/parters02.gif" alt="友情链接"/>
					</td>
					<td class="linktitle">
					<h3>
						<a href="{forumlink[url]}" target="_blank">{forumlink[name]}</a>
					</h3>
					<p>{forumlink[note]}</p>
					</td>
					<td class="linklogo">
						<a href="{forumlink[url]}" target="_blank"><img src="{forumlink[logo]}" alt="{forumlink[name]}"/></a>
					</td>
				</tr>
			</tbody>
			<%else if {forumlink[name]}!="$$otherlink$$"%>
			<tbody>
				<tr class="list">
					<td class="topicicon">
						<img src="templates/{templatepath}/images/parters02.gif" alt="友情链接"/>
					</td>
					<td colspan="2"  class="linktitle">
					<h3>
						<a href="{forumlink[url]}" target="_blank">{forumlink[name]}</a>
					</h3>
					<p>{forumlink[note]}</p>
					</td>
				</tr>
			</tbody>
			<%else%>
			<tbody>
				<tr class="list">
					<td  class="topicicon">
						<img src="templates/{templatepath}/images/parters02.gif" alt="友情链接"/>
					</td>
					<td colspan="2"  class="linktitle">
						{forumlink[note]}
					</td>
			   </tr>
			</tbody>
			<%/if%>
		<%/loop%>
		</table>
	</div>
</div>
<%/if%>

<%if {config.whosonlinestatus}!=0 && {config.whosonlinestatus}!=2%>
<div class="onlineuser">
	<span class="open">
		<%if {request[showonline]}=="no"%>
			<a href="?showonline=yes#online" class="opentopic"><img src="templates/{templatepath}/images/open_yes.gif" alt="展开/收起" />
		<%else%>
			<a href="?showonline=no#online"  class="opentopic"><img src="templates/{templatepath}/images/open_no.gif" alt="展开/收起" />
		<%/if%>	</a>
	</span>
	<h4>
		<strong>在线用户:{totalonline}人</strong>
		<em>最高纪录是 <strong>{highestonlineusercount}</strong>  于 /  {highestonlineusertime} </em>	
	</h4>
	<dl class="onlineuserlist">
		<dt>{onlineiconlist}</dt>
		<dd class="onlineusernumber">
			共<strong>{totalusers}</strong>位会员 <span class="newuser">新会员:
			<%set {aspxrewriteurl} = this.UserInfoAspxRewrite({lastuserid})%>
			<a href="{aspxrewriteurl}">{lastusername}</a></span>
		</dd>
		<dd>
			<ul id="online">
			<%if {showforumonline}%>
				<%loop (OnlineUserInfo) onlineuser onlineuserlist%>
					<%if {onlineuser.invisible}==1%>
				<li>(隐身会员)</li>
					<%else%>
				<li>{onlineuser.olimg}
						<%if {onlineuser.userid}==-1%>
							{onlineuser.username}
						<%else%>
						   <%set {aspxrewriteurl} = this.UserInfoAspxRewrite({onlineuser.userid})%>
							<a href="{aspxrewriteurl}" target="_blank">{onlineuser.username}</a>
						<%/if%>
				</li>
					<%/if%>
				<%/loop%>
			<%else%>
				<li class="seelist"><a href="?showonline=yes#online">点击查看在线列表</a></li>
			<%/if%>
			</ul>
		</dd>
	</dl>
</div>
<%/if%>
<div id="navcutline">
		<strong>无新帖的论坛</strong>
		<em>有新帖的论坛</em>
</div>
<%if {config.forumjump}==1%>
	{navhomemenu}
<%/if%>
</div>
<%template _copyright%>
<%template _adlist%>
{mediaad}
{inforumad}
<%template _footer%>