<!--<?php print <<<EOT
--><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=$db_charset" />
<title>$subject$forumtitle$db_bbsname - Powered by PHPWind.net</title>
<meta name="generator" content="PHPWind $wind_version" />
<meta name="keywords" content="$db_metakeyword" />
<meta name="description" content="$db_metadescrip" />
<link rel='archives' title='$db_bbsname' href='$db_bbsurl/simple' />
<link rel="alternate" type="application/rss+xml" title="RSS" href="$db_bbsurl/rss.php?fid=$fid" />
<base id="headbase" href="$db_bbsurl/" />
<link href="$pwModeImg/style.css" rel="stylesheet" type="text/css" />
<link href="$pwModeImg/mode.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" language="JavaScript" src="js/pw_ajax.js"></script>
<script language="JavaScript">
var agt = navigator.userAgent.toLowerCase();
var is_ie = ((agt.indexOf("msie") != -1) && (agt.indexOf("opera") == -1));
var is_gecko= (navigator.product == "Gecko");
var imgpath = '$imgpath';
var modeimg = '$pwModeImg';
var verifyhash = '$verifyhash';
if (location.href.indexOf('/simple/') != -1) {
	getObj('headbase').href = location.href.substr(0,location.href.indexOf('/simple/')+1);
} else if (location.href.indexOf('.html')!=-1) {
	var base = location.href.replace(/^(http(s)?:\/\/(.*?)\/)[^\/]*\/[0-9]+\/[0-9]{4,6}\/[0-9]+\.html$/i,'$1');
	if (base != location.href) {
		getObj('headbase').href = base;
	}
}
function getObj(id) {
	return document.getElementById(id);
}
function ietruebody() {
	return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body;
}
function getTop() {
	return typeof window.pageYOffset != 'undefined' ? window.pageYOffset:ietruebody().scrollTop;
}
function getLeft() {
	return (typeof window.pageXOffset != 'undefined' ? window.pageXOffset:ietruebody().scrollLeft)
}
function IsElement(id) {
	return document.getElementById(id) != null ? true : false;
}
function setCurrent(src,dst,css) {
	var o = null;
	if (IsElement(src)) {
		o = getObj(src);
	} else if (dst && IsElement(dst)) {
		o = getObj(dst);
	}
	if (o) o.className += ' ' + css;
}
</script>
</head>
<body onkeydown="try{keyCodes(event);}catch(e){}">
$msgsound
<div id="mode-header">
	<div class="mode-header">
    	<div class="mode-head">
            <a href="./" class="logo fl"><img src="$pwModeImg/logo.png" /><h1>站點名稱</h1></a>
            <div class="login fr">
<!--
EOT;
if($groupid=='guest'){
$arr_logintypename = array('用戶名','UID','Email');
print <<<EOT
-->
				<p><a onclick="showLoginDiv();" title="展開登錄框" class="ml" style="cursor:pointer">登錄</a><a href="$regurl">免費注冊</a></p>
				<div id="user-login" class="menu menu-post" style="display:none">
                	<div class="menu-b" style="width:400px;">
					<form $actionurl name="login_FORM" method="post">
						<input type="hidden" name="jumpurl" value="http://{$pwServer['HTTP_HOST']}{$REQUEST_URI}" />
						<input type="hidden" name="step" value="2" />
						<input type="hidden" name="cktime" value="31536000" />
						<table width="100%" cellpadding="0" cellspacing="0">
                        	<tr><td class="menu-top" colspan="2">登錄</td></tr>
							<tr class="user-table">
								<td width="30%"><select name="lgt">
<!--
EOT;
if(count($arr_logintype)==1){
$value = current($arr_logintype);
print <<<EOT
-->
									<option value="$value" selected>$arr_logintypename[$value]</option>
<!--
EOT;
}elseif(count($arr_logintype)>1){
$i=1;
foreach($arr_logintype as $value){
$str_checked = $i==1? 'selected':'';
$i++;
print <<<EOT
-->
									<option value="$value" $str_checked>$arr_logintypename[$value]</option>
<!--
EOT;
}print <<<EOT
-->
									</select>
<!--
EOT;
}else{print <<<EOT
-->

									<input type="radio" name="lgt" value="$value" checked /><span id="login_$value">用戶名</span>
<!--
EOT;
}print <<<EOT
-->
								</td>
								<td class="tal"><input class="input gray" onfocus="checkinput(this);" onblur="if(getObj('logintab')) getObj('logintab').style.display='';checkinput(this,'輸入用戶名');" style="width:150px" name="pwuser" value="輸入用戶名" tabindex="1" /></td>
							</tr>
							<tr class="user-table">
								<td>密  碼</td><td class="tal"><input class="input" type="password" name="pwpwd" style="width:150px;" tabindex="2" /></td>
							</tr>
<!--
EOT;
if($db_gdcheck & 2){print <<<EOT
-->
							<tr class="user-table">
								<td>認證碼</td>
								<td class="tal">
									<input class="input" onfocus="showCK();" type="text" name="gdcode" size="5" tabindex="3"  />
									<img id="ckcode" style="cursor:pointer;display:none" onclick="this.src='ck.php?nowtime='+new Date().getTime();" alt="看不清楚，換一張" />
								</td>
							</tr>
<!--
EOT;
}if($db_ifsafecv){print <<<EOT
-->
							<tr class="user-table">
								<td>安全問題</td>
								<td class="tal">
									<select name="question" onchange="showcustomquest(this.value)" tabindex="4">
										<option value="0">無安全問題</option>
	<option value="1">我爸爸的出生地</option>
	<option value="2">我媽媽的出生地</option>
	<option value="3">我的小學校名</option>
	<option value="4">我的中學校名</option>
	<option value="5">我最喜歡的運動</option>
	<option value="6">我最喜歡的歌曲</option>
	<option value="7">我最喜歡的電影</option>
	<option value="8">我最喜歡的顏色</option>
	<option value="-1">自定義問題</option>
									</select>
									<input id="customquest" style="display:none" name="customquest" class="input" size="10" tabindex="5" />
								</td>
							</tr>
							<tr class="user-table">
								<td>您的答案</td>
								<td class="tal"><input name="answer" class="input" size="25" tabindex="6" /></td>
							</tr>
<!--
EOT;
}if($qcheck){print <<<EOT
-->
							<tr class="user-table">
								<td>驗證問答</td>
								<td class="tal">{$db_question[$qkey]}<br />
									<input class="input" name="qanswer" size="25" tabindex="7" />
									<input type="hidden" name="qkey" value="$qkey" />
								</td>
							</tr>
<!--
EOT;
}print <<<EOT
-->


							<tr class="user-table">
								<td></td>
								<td class="tal"><input class="menu-btn fl" type="submit" value="登 錄" tabindex="8" /> <a href="sendpwd.php" class="fl">忘記密碼</a></td>
							</tr>
						</table>
					</form>
                    </div>
				</div>
<script language="JavaScript">
function showcustomquest(qid){
	getObj('customquest').style.display = qid==-1 ? '' : 'none';
}
function checkinput(obj,val){
	if (obj.className.indexOf('gray')!=-1) {
		obj.value = '';
		obj.className = obj.className.replace('gray', 'black');
	} else if (val && obj.value=='') {
		obj.value = obj.defaultValue = val;
		if (obj.className.indexOf('black') == -1) {
			obj.className += ' gray';
		} else {
			obj.className = obj.className.replace('black', 'gray');
		}
	}
}
var mt;
function showLoginDiv(){
	mt = setTimeout('read.open(\'user-login\',\'show-login\',2,26);',200);
	document.onmousedown = function (e) {
		var o = is_ie ? window.event.srcElement : e.target;
		if (!issrc(o)) {
			read.close();
			document.onmousedown = '';
		}
	}
}
function issrc(o) {
	var k = 0;
	while (o) {
		if (o == read.menu) {
			return true;
		}
		if (o.tagName.toLowerCase() == 'body' || ++k>10) {
			break;
		}
		o = o.parentNode;
	}
	return false;
}
function showCK(){
	getObj('ckcode').style.display="";
	if (getObj('ckcode').src.indexOf('ck.php') == -1) {
		getObj('ckcode').src = 'ck.php?nowtime=' + new Date().getTime();
	}
}
<!--
EOT;
if($ajaxlogin){print <<<EOT
-->
function ajax_login(obj) {
	try {
		ajax.send(obj.action,obj,function() {
			if (ajax.request.responseText.indexOf('<split />') != -1) {
				var str = ajax.request.responseText.split('<split />');
				getObj('user_info').innerHTML = str[0];
				getObj('user-login').innerHTML = str[1];
				getObj('menu_guide').innerHTML = str[2];
			} else {
				ajax.guide();
			}
		});
	} catch(e){alert('數據加載未完成,請稍候重試!');}
	return false;
}
<!--
EOT;
}print <<<EOT
-->
</script>							
<!--
EOT;
} else {print <<<EOT
-->
            	<div class="login-img fl"><a href="u.php"><img src="$faceurl" /></a></div>
                <a href="u.php" class="user b"><span>$windid</span></a>
                <p><a href="profile.php">個人設置</a><a id="td_msg" href="message.php">
<!--
EOT;
if($winddb[newpm]>0 && $_G[maxmsg]>0){print <<<EOT
-->
					<img src="$imgpath/$stylepath/shortmail.gif"/>
<!--
EOT;
} else {print <<<EOT
-->
					<img src="$imgpath/$stylepath/no-shortmail.gif"/>
<!--
EOT;
}print <<<EOT
-->
				</a>
                <a href="$loginouturl">退出</a></p>
<!--
EOT;
}print <<<EOT
-->
			</div>
            <ul class="mode-toptool fr">
            	$head_navigation
<!--
EOT;
if ($head_nav_more) {print <<<EOT
-->
				<li><a class="nav-more" onclick="read.open('menu_nav_more','td_nav_more');" style="cursor:pointer;" id="td_nav_more">更多</a></li>
<!--
EOT;
}print <<<EOT
-->
            </ul>
            $head_nav_more
        </div>
        <div class="c"></div>
	</div>
        <div class="mode-guide">
            <ul>
				 
<!--
EOT;
if ($db_mode == 'area') {
print <<<EOT
-->
				<li class="active" class="active"><a href="$db_bbsurl?m=area">首 頁</a></li> 
                <li id="h_index"><a href="$db_bbsurl?m=default">討論區</a></li>
<!--
EOT;
}else{print <<<EOT
-->
				<li class="nobg"><a href="$db_bbsurl?m=area">首 頁</a></li> 
				<li id="h_index" class="active"><a href="$db_bbsurl?m=default">討論區</a></li>
<!--
EOT;
}print <<<EOT
-->
            </ul>
            <span class="one">
<!--
EOT;
if($_G[allowmember]){print <<<EOT
-->
                <a href="member.php">會員</a>
<!--
EOT;
}if($_G[allowsort]){print <<<EOT
-->
                <a id="td_sort" href="sort.php">統計排行</a>
<!--
EOT;
}if($_G['show']){print <<<EOT
-->
                <a href="show.php" id="h_show">展區</a>
<!--
EOT;
}if($db_iftag){print <<<EOT
-->
                <a id="h_job" href="job.php?action=taglist">標簽</a>
<!--
EOT;
}print <<<EOT
-->
                <a href="push.php?fid=$fid" id="h_push">推薦</a>
                <a href="search.php" id="h_search" id="h_hack">搜索</a>
                <a style="cursor:pointer;" id="td_hack">社區服務</a>
<!--
EOT;
foreach($db_hackdb as $key=>$hack){
if($hack[2]=='2' && file_exists(R_P."hack/$key/index.php")){print <<<EOT
-->
				<a href="hack.php?H_name=$hack[1]">$hack[0]</a>
<!--
EOT;
}}if($db_ifbookinfo){
$rawbbsname=rawurlencode($db_bbsname);
$rawbbsurl=rawurlencode($db_bbsurl);
$rawuser=rawurlencode($windid);
$pushurl="http://push.phpwind.com/book.php?tocharset=$db_charset&bbsname=$rawbbsname&bbsurl=$rawbbsurl&user=$rawuser";
if($tid){
$rawtitle=rawurlencode($subject);
print <<<EOT
-->
							<a href="$pushurl&tid=$tid&title=$rawtitle" target="_blank">訂閱本帖更新</a>
<!--
EOT;
}elseif($fid){
$rawforumname=rawurlencode($forumname);
print <<<EOT
-->
							<a href="$pushurl&fid=$fid&forumname=$rawforumname" target="_blank">訂閱本版更新</a>
<!--
EOT;
}else{print <<<EOT
-->
							<a href="$pushurl" target="_blank">訂閱全站新帖</a>
<!--
EOT;
}}if(CkInArray($windid,$manager) || $SYSTEM['allowadmincp']){print <<<EOT
-->
							<a href="$db_adminfile" target="_blank">系統設置</a>
<!--
EOT;
}print <<<EOT
-->
</span>

        </div>
		<div id="menu_hack" class="menu2" style="display:none;">
			<dl>
<!--
EOT;
foreach ($db_hackdb as $key => $hack) {
if ($hack[2]=='1' && file_exists(R_P."hack/$key/index.php")) {print <<<EOT
-->
				<dd><a href="hack.php?H_name=$hack[1]">$hack[0]</a></dt>
<!--
EOT;
}}print <<<EOT
-->
			</dl>
		</div>
<!--
EOT;
if($db_menu%2 == 1){print <<<EOT
-->

		<div id="menu_sort" class="menu2" style="display:none;">
			<dl>
				<dd><a href="sort.php">基本統計信息</a></dd>
				<dd><a href="sort.php?action=ipstate">到訪IP統計</a></dd>
				<dd><a href="sort.php?action=team">管理團隊</a></dd>
				<dd><a href="sort.php?action=admin">管理統計</a></dd>
				<dd><a href="sort.php?action=online">在線統計</a></dd>
				<dd><a href="sort.php?action=member">會員排行</a></dd>
				<dd><a href="sort.php?action=forum">版塊排行</a></dd>
				<dd><a href="sort.php?action=article">帖子排行</a></dd>
			</dl>
		</div>
<!--
EOT;
}print <<<EOT
-->
	<div class="c"></div>
</div>
<div class="c"></div>
<div class="mode-main cc">
<div class="fl" style="margin-right:15px;width:150px;">
			<a onclick="read.open('menu_post_nav','',2);" class="h-post" style="cursor:pointer;" id="post_nav">發貼</a>
			$head_postlist
<!--
EOT;
if ($db_menu%4>=2) {print <<<EOT
-->
            <a onclick="read.open('menu_cate_nav','',2);" class="h-guide ml" style="cursor:pointer;" id="index_nav">導航</a>
			$head_forumlist
<!--
EOT;
}print <<<EOT
-->
</div>
		<ul class="mode-forum fl">
			<!--<li><a href="index.php" class="active"><span>首頁</span></a></li>-->
<!--
EOT;
foreach($catedbs as $key => $value){
if($value){print <<<EOT
-->
	   		<li><a href="thread.php?fid=$key" title="$value"><span>$value</span></a></li>
<!--
EOT;
}}print <<<EOT
-->
		</ul>
<div class="c"></div>
</div>
<div id="mode-main">
<div class="c"></div>
   	<div class="mode-main">
<div class="top-ad tac">$header_ad</div>
<!--
EOT;
?>-->
