{template header}
<div class="subtable nav" style="width: {TABLEWIDTH}">
<a href="$indexname">$bbname</a> &raquo; {lang stats}
</div><br>

<table cellspacing="0" cellpadding="0" border="0" width="{TABLEWIDTH}" align="center">
<tr><td width="200" valign="top">
<div class="spaceborder" style="width: 186px !important; width: 191px; background: {ALTBG1}">
{template stats_navbar}
</div>
</td>
<td valign="top">

<!--{if $type == 'views'}-->
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: left;">{lang stats_week}:</div>
	<table border="0" cellspacing="0" cellpadding="{TABLESPACE}" width="100%" class="smalltxt">
	$statsbar_week
	</table></div><br>
	
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: left;">{lang stats_hour}:</div>
	<table border="0" cellspacing="0" cellpadding="{TABLESPACE}" width="100%" class="smalltxt">
	$statsbar_hour
	</table></div><br>
	
<!--{elseif $type == 'agent'}-->
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: left;">{lang stats_os}:</div>
	<table border="0" cellspacing="0" cellpadding="{TABLESPACE}" width="100%" class="smalltxt">
	$statsbar_os
	</table></div><br>

	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: left;">{lang stats_browser}:</div>
	<table border="0" cellspacing="0" cellpadding="{TABLESPACE}" width="100%" class="smalltxt">
	$statsbar_browser
	</table></div><br>
<!--{elseif $type == 'posts'}-->
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: left;">{lang stats_month_posts}:</div>
	<table border="0" cellspacing="0" cellpadding="{TABLESPACE}" width="100%" class="smalltxt">
	$statsbar_monthposts
	</table></div><br>

	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: left;">{lang stats_day_posts}:</div>
	<table border="0" cellspacing="0" cellpadding="{TABLESPACE}" width="100%" class="smalltxt">
	$statsbar_dayposts
	</table></div><br>
<!--{elseif $type == 'forumsrank'}-->
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: center;">{lang stats_forums_rank}</div>
	<table width="100%" cellpadding="{TABLESPACE}" cellspacing="{INNERBORDERWIDTH}">	
	<tr class="category" align="center"><td colspan="3">{lang stats_posts} {lang stats_rank}</td><td colspan="3">{lang reply} {lang stats_rank}</td><td colspan="3">{lang stats_posts_thismonth} {lang stats_rank}</td><td colspan="3">{lang stats_posts_today} {lang stats_rank}</td></tr>
	$forumsrank</table>
	</div>
	<br>
	<div style="border: 1px solid {CATBORDER}; {CATBGCODE}; margin: 0px; padding:8px; text-align: left">
	<img src="images/common/notice.gif"> {lang stats_update}</div>

<!--{elseif $type == 'threadsrank'}-->
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: center;">{lang stats_threads_rank}</div>
	<table width="100%" cellpadding="{TABLESPACE}" cellspacing="{INNERBORDERWIDTH}">
	<tr align="center" class="category">
	<td colspan="3">{lang stats_threads_most_views}</td>
	<td colspan="2">{lang stats_threads_most_replies}</td></tr>
	$threadsrank
	</table>
	</div>
	<br>
<!--{elseif $type == 'postsrank'}-->
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: center;">{lang stats_posts_rank}</div>
	<table width="100%" cellpadding="{TABLESPACE}" cellspacing="{INNERBORDERWIDTH}">
	<tr align="center" class="category">
	<td width="23%" colspan="3">{lang stats_posts} {lang stats_rank}</td>
	<td width="23%" colspan="3">{lang stats_digest_posts} {lang stats_rank}</td>
	<td width="23%" colspan="3">{lang stats_posts_thismonth} {lang stats_rank}</td>
	<td width="23%" colspan="2">{lang stats_posts_today} {lang stats_rank}</td></tr>
	$postsrank
	</td></table>
	</div>
	<br>
<!--{elseif $type == 'creditsrank'}-->
	<div class="simpletable" style="width: 100%;">
	<div class="header" style="text-align: center;">{lang stats_credits_rank}</div>
	<table width="100%" cellpadding="{TABLESPACE}" cellspacing="{INNERBORDERWIDTH}">
	<tr align="center" class="category">
	<td width="$columnwidth" colspan="2">{lang credits} {lang stats_rank}</td>
	<!--{loop $arrextcredits[0] $id $credit}-->
		<td colspan="3">$credit[title] {lang stats_rank}</td>
	<!--{/loop}-->
	</tr>
	$creditsrank[0]
	</td></table>	
	</div>
	<br>
	<!--{if !empty($arrextcredits[1])}-->
	<div class="simpletable" style="width: 100%;">
	<div class="header" style="text-align: center;">{lang stats_credits_rank}</div>
	<table width="100%" cellpadding="{TABLESPACE}" cellspacing="{INNERBORDERWIDTH}">
	<tr align="center" class="category">
	<!--{loop $arrextcredits[1] $id $credit}-->
		<td colspan="3">$credit[title] {lang stats_rank}</td>
	<!--{/loop}-->
	</tr>
	$creditsrank[1]
	</td></table>	
	</div>
	<!--{/if}-->
<!--{elseif $type == 'modworks' && $uid}-->
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: center;">{lang stats_modworks} - $member[username]</div>
	<table width="100%" cellpadding="{TABLESPACE}" cellspacing="{INNERBORDERWIDTH}">
	<tr class="category" align=center><td width="8%">{lang time}</td><!--{loop $modactioncode $key $val}--><td width="$tdwidth">$val</td><!--{/loop}--></tr>
	<!--{loop $modactions $day $modaction}-->
		<tr align="center" class="row" onMouseOver="this.style.backgroundColor='{ALTBG1}'" onMouseOut="this.style.backgroundColor='{ALTBG2}'">
		<td><span class="smalltxt">$day</span></td>
		<!--{loop $modactioncode $key $val}-->
			<!--{if $modaction[$key]['posts']}--><td title="{lang posts}: $modaction[$key][posts]">$modaction[$key][count]<!--{else}--><td>&nbsp;<!--{/if}--></td>
		<!--{/loop}-->
		</tr>
	<!--{/loop}-->
	<tr class="singleborder"><td colspan="$tdcols"></td></tr>
	<tr align="center">
	<td class="altbg1">{lang stats_modworks_thismonth}</td>
	<!--{loop $modactioncode $key $val}-->
		<td class="$bgarray[$key]" <!--{if $totalactions[$key]['posts']}-->title="{lang posts}: {$totalactions[$key][posts]}"<!--{/if}-->>$totalactions[$key][count]</td>
	<!--{/loop}-->
	</tr>
	</table>
	</div>
	
	<table cellspacing="0" cellpadding="4" border="0" width="100%%" align="center" class="smalltxt">
	<tr><td align="right">{lang stats_modworks_month}: <!--{loop $monthlinks $link}--> &nbsp;{$link}&nbsp; <!--{/loop}-->
	</td></tr></table><br>
	
	
<!--{elseif $type == 'modworks'}-->
	<div class="simpletable" style="width:100%;">
	<div class="header" style="text-align: center;">{lang stats_modworks} - {lang stats_modworks_all}</div>
	<table width="100%" cellpadding="{TABLESPACE}" cellspacing="{INNERBORDERWIDTH}">
	
	<tr class="category" align=center><td width="8%">{lang username}</td><!--{loop $modactioncode $key $val}--><td width="$tdwidth">$val</td><!--{/loop}--></tr>
	<!--{loop $members $uid $member}-->
		<tr align="center" class="row" onMouseOver="this.style.backgroundColor='{ALTBG1}'" onMouseOut="this.style.backgroundColor='{ALTBG2}'">
		<td><a href="stats.php?type=modworks&before=$before&uid=$uid" title="{lang stats_modworks_details}">{$member[username]}</a></td>
		<!--{loop $modactioncode $key $val}-->
			<!--{if $member[$key]['posts']}--><td title="{lang posts}: {$member[$key]['posts']}"><span class="smalltxt">{$member[$key][count]}</span><!--{else}--><td>&nbsp;<!--{/if}--></td>
		<!--{/loop}-->
		</tr>
	<!--{/loop}-->
	</table>
	</div>
	<table cellspacing="0" cellpadding="4" border="0" width="95%" align="center" class="smalltxt">
	<tr><td align="right">{lang stats_modworks_month}: <!--{loop $monthlinks $link}--> &nbsp;{$link}&nbsp; <!--{/loop}-->
	</td></tr></table><br>
<!--{/if}-->

</td></tr></table>
{template footer}