<!--<?php
if($action=='leaveword'){print <<<EOT
-->
<form action="pw_ajax.php?action=$action" method="post" onsubmit="return false;">
<input type="hidden" name="verify" value="$verifyhash" />
<div class="bor">
<table width="100%" cellspacing="0" cellpadding="5">
<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>樓主留言</th></tr>
	<tr><td width="20%" align="center">消息通知︰</td><td><input type="radio" name="ifmsg" value="1" />是 <input type="radio" name="ifmsg" value="0" checked />否</td></tr>
	<tr><td align="center">留言內容︰</td><td>
<!--
EOT;
if($db_adminreason){print <<<EOT
-->
		<select name="" style="width:70px" size="6" multiple onchange="this.form.atc_content.value=this.value">
			<option value="">自定義</option>
			<option value="">-------</option>
			$reason_sel
		</select>
<!--
EOT;
}print <<<EOT
-->
		<textarea name="atc_content" onkeydown="ajax.quickpost(event,this.form)" style="width:180px;height:92px">$rt[leaveword]</textarea>
	</td></td></tr>
</table>
<input type="hidden" name="step" value="2" />
<input type="hidden" name="tid" value="$tid" />
<input type="hidden" name="pid" value="$pid" />
<ul><li style="text-align:center;padding:4px 0 5px;"><input type="button" class="btn" name="ajaxsubmit" onclick="ajax.submit(this.form,worded);" value="提 交" /></li></ul></form>
</div>
<!--
EOT;
}elseif($action=='favor'){print <<<EOT
-->
<div class="bor">
<table cellspacing="0" cellpadding="5" width="100%">
<tr><th class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>選擇分類</th></tr>

<!--
EOT;
foreach($typeid as $key=>$value){
if ($key == '0') {
print <<<EOT
-->
<tr><td><a onclick="favor('0');" href="javascript:">默認分類</a></td></tr>
<!--
EOT;
} else {print <<<EOT
-->
<tr><td><a onclick="favor('$key');return false;" href="javascript:">$value</a></td></tr>
<!--
EOT;
}}print <<<EOT
-->
</table>
</div>
<!--
EOT;
}elseif($action=='relatetag'){print <<<EOT
-->
<div class="bor">
<table cellspacing="0" cellpadding="5" width="100%">
	<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>標簽:$tagname</th></tr><tr><td>
	<ul>
<!--
EOT;
foreach($readdb as $key=>$value){print <<<EOT
-->
	<li style="height:25px;line-height:25px;overflow:hidden;"><a href="read.php?tid=$value[tid]" class="a6">$value[subject]</a></li>
<!--
EOT;
}print <<<EOT
-->
	<li><a class="fr a6" href="job.php?action=tag&tagname=$tagname">更多內容</a></li>
	</ul></td></tr>
</table>
</div>
<!--
EOT;
}elseif($action=='draft'){print <<<EOT
-->
<div class="bor">
<table cellspacing="0" cellpadding="5" width="100%">
	<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>草稿箱</th></tr>
<!--
EOT;
$i=($page-1)*$db_showperpage;
foreach($drdb as $key=>$value){
$i++;
print <<<EOT
-->
	<tr class="tr3 tac">
		<td width="9%">$i</td>
		<td class="tal"><textarea style="width:256px;height:35px; margin:.2em">{$value[content]}</textarea> <img style="cursor:pointer" src="$imgpath/post/c_editor/insert.gif" onclick="draft.insert(this)" alt="插入" /> <img style="cursor:pointer" src="$imgpath/post/c_editor/save.gif" onclick="draft.update(this,'$value[did]')" alt="保存" /> <img style="cursor:pointer" src="$imgpath/post/c_editor/del.gif" alt="刪除" onclick="draft.del('$value[did]','$page')"/></td>
	</tr>
<!--
EOT;
}if($maxpage>1){print <<<EOT
-->
	<tr class="tr3"><td colspan="2">
<!--
EOT;
if($page>1){print <<<EOT
-->
	<a class="fl" style="cursor:pointer" onclick="draft.prev('$page');">上一頁</a>
<!--
EOT;
}if($page<$maxpage){print <<<EOT
-->
	<a class="fr" style="cursor:pointer" onclick="draft.next('$page');">下一頁</a>
<!--
EOT;
}print <<<EOT
-->
	</td></tr>
<!--
EOT;
}print <<<EOT
-->
</table>
</div>
<!--
EOT;
}if($action=='login'){print <<<EOT
-->
<a href="u.php"><img src="$faceurl" onmouseout="clearTimeout(mt);read.close();"  onmouseover="mt=setTimeout('read.open(\'showface\',\'sf\',\'4\');',700);" style="float:left; margin-top:.4em;width:40px;height:40px;"/></a>

						<div style="padding:0 0 0 1em;margin:0 0 0 45px">
							<span id="sf" style="position:absolute; *margin:0 0 0 -.5em;"></span> <span class="user-infotwo" id="showface" style="display:none"> <span class="user-infoWraptwo"> <span class="co"></span>
							<a href="profile.php?action=modify&info_type=face">更換頭像</a><br />
							UID: $winduid <br />
							$db_rvrcname: <span class="s2 f10">$userrvrc $db_rvrcunit</span><br />
							$db_moneyname: <span class="s3 f10">$winddb[money] $db_moneyunit</span><br />
							$db_creditname: <span class="s3 f10">$winddb[credit] $db_creditunit</span><br />
							<span class="gray f10"> 最後登錄: {$lastlodate}<br />
							登錄IP: $onlineip<br />
							</span> </span> </span>
						</div>
						<div style="margin-left:50px; line-height:180%">
						<div class="fl" style="width:100%">
							<div class="gray3" style="float:left;clear:right"><span class="fl">等級:$gp_grouptitle, 帖子:$winddb[postnum], <a href="u.php?action=topic" class="link5">我的主題</a> <a href="u.php?action=post" class="link5">我的回復</a>&nbsp;</span><div class="fl" style="margin:.4em 1em 0 0"><a class="dropB" id="td_u">更多</a></div><span class="fl">
<!--
EOT;
if (SCR == 'index' && ($groupid == 3 || $groupid == 4)) {print <<<EOT
-->
								<a style="cursor:pointer" onclick="if (typeof MgMode == 'function') {mgm.showMenu();} else {loadjs('js/mgmode.js');}">可視化布局</a>
<!--
EOT;
}if($db_replysitemail && getstatus($winddb['userstatus'],6)){print <<<EOT
-->
							| <a id="newrp" onclick="sendmsg('pw_ajax.php','action=newrp',this.id)" style="cursor:pointer;" class="s3">您的文章有人回復</a>
<script language="JavaScript">
function newrp() {
	ajax.guide();
	ajax.send('pw_ajax.php','action=newrp',function(){
		if (ajax.request.responseText.indexOf('<') != -1) {
			read.menu.innerHTML = ajax.request.responseText;
		} else {
			closep();
			getObj('newrp').parentNode.removeChild(getObj('newrp'));
		}
	});
}
</script>
<!--
EOT;
}print <<<EOT
-->
							</span></div>
<!--
EOT;
if($_G[allowhonor]){print <<<EOT
-->						<div class="c"></div>
							<span id="honor">
<!--
EOT;
if($winddb['honor']){print <<<EOT
-->
									{$winddb[honor]}
<!--
EOT;
}else{print <<<EOT
-->
您還沒有設置個性簽名
<!--
EOT;
}print <<<EOT
-->
							</span>
							<a id="sethonor" onclick="sendmsg('pw_ajax.php','action=honor',this.id)" class="gray3" style="cursor:pointer"><img src="$imgpath/$stylepath/infobox-edit.gif" />編輯</a>
							<div class="c"></div>
<script language="JavaScript">
function honor() {
	var str = ajax.request.responseText.split("\t");
	if (str[0] == 'success') {
		getObj('honor').innerHTML = '&nbsp;' + (str[1] ? str[1] : '您還沒有設置個性簽名') + '&nbsp;';
	} else {
		ajax.guide();
	}
}
</script>
<!--
EOT;
}print <<<EOT
-->

						</div></div>
	<split />
<!--
EOT;
if($groupid=='guest'){print <<<EOT
-->
							<a href="$loginurl" style="color:#c3e4f5">登錄</a> &nbsp;<a href="$regurl" style="color:#c3e4f5">注冊</a>
<!--
EOT;
}else{print <<<EOT
-->
							<a href="u.php" style="color:#fff; font-weight:700">$windid</a> <a id="td_msg" href="message.php">
<!--
EOT;
if($winddb[newpm]>0 && $_G[maxmsg]>0){print <<<EOT
-->
								<img src="$imgpath/$stylepath/meg.gif" align="absmiddle"/>
<!--
EOT;
} else {print <<<EOT
-->
								<img src="$imgpath/$stylepath/meg-read.gif" align="absmiddle"/>
<!--
EOT;
}print <<<EOT
-->
							</a>
							<a href="profile.php" style="color:#c3e4f5">設置</a> <a href="$loginouturl" style="color:#c3e4f5">退出</a>
<!--
EOT;
}print <<<EOT
-->
	<split />
	<li id="h_index"><a href="$db_bbsurl">討論區</a></li>
<!--
EOT;
if($winduid){
if($db_menu%2 == 1){
print <<<EOT
-->
	<li id="h_profile"><a id="td_profile" style="cursor:pointer;" onMouseOver="read.open('menu_profile','td_profile');">用戶中心$menu_down</a></li>
<!--
EOT;
}else{print <<<EOT
-->
	<li id="h_profile"><a id="td_profile" href="profile.php">用戶中心</a></li>
<!--
EOT;
}}if($_G[allowsort]){
if($db_menu%2 == 1){
print <<<EOT
-->
	<li id="h_sort"><a style="cursor:pointer;" id="td_sort" onMouseOver="read.open('menu_sort','td_sort');">統計排行$menu_down</a></li>
<!--
EOT;
}else{print <<<EOT
-->
	<li id="h_sort"><a id="td_sort" href="sort.php">統計排行</a></li>
<!--
EOT;
}}if($_G[allowmember]){print <<<EOT
-->
	<li id="h_member"><a href="member.php">會員</a></li>
<!--
EOT;
}if($_G['show']){print <<<EOT
-->
	<li id="h_show"><a href="show.php">展區</a></li>
<!--
EOT;
}if($db_iftag){print <<<EOT
-->
	<li id="h_job"><a href="job.php?action=taglist">標簽</a></li>
<!--
EOT;
}print <<<EOT
-->
	<li id="h_push"><a href="push.php?fid=$fid">推薦</a></li>
	<li id="h_search"><a href="search.php">搜索</a></li>
	<li id="h_hack"><a style="cursor:pointer;" id="td_hack" onMouseOver="read.open('menu_hack','td_hack');">社區服務$menu_down</a></li>
<!--
EOT;
foreach($db_hackdb as $key=>$hack){
if($hack[2]=='2' && file_exists(R_P."hack/$key/index.php")){print <<<EOT
-->
	<li><a href="hack.php?H_name=$hack[1]">$hack[0]</a></li>
<!--
EOT;
}}if($db_ifbookinfo){
$rawbbsname=rawurlencode($db_bbsname);
$rawbbsurl=rawurlencode($db_bbsurl);
$rawuser=rawurlencode($windid);
$pushurl="http://push.phpwind.net/book.php?tocharset=$db_charset&bbsname=$rawbbsname&bbsurl=$rawbbsurl&user=$rawuser";
if($tid){
$rawtitle=rawurlencode($subject);
print <<<EOT
-->
	<li><a href="$pushurl&tid=$tid&title=$rawtitle" target="_blank">訂閱本帖更新</a></li>
<!--
EOT;
}elseif($fid){
$rawforumname=rawurlencode($forumname);
print <<<EOT
-->
	<li><a href="$pushurl&fid=$fid&forumname=$rawforumname" target="_blank">訂閱本版更新</a></li>
<!--
EOT;
}else{print <<<EOT
-->
	<li><a href="$pushurl" target="_blank">訂閱全站新帖</a></li>
<!--
EOT;
}}if(CkInArray($windid,$manager) || $SYSTEM['allowadmincp']){print <<<EOT
-->
	<li><a href="$db_adminfile" target="_blank">系統設置</a></li>
<!--
EOT;
}}elseif($action=='msg'){print <<<EOT
-->
<form action="pw_ajax.php?action=$action" method="post" onsubmit="return false;">
<input type="hidden" name="verify" value="$verifyhash" />
<input type="hidden" name="step" value="2" />
<div class="bor">
<table cellspacing="0" cellpadding="5" width="100%">
	<tbody>
	<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>發送短消息</th></tr>
	<tr><td width="15%" align="center">用戶︰</td><td><input type="text" class="input" name="pwuser" value="$reinfo[username]" /></td></tr>
	<tr><td align="center">標題︰</td><td><input type="text" class="input" name="msg_title" maxlength="100" size="50" /></td></tr>
<!--
EOT;
if($db_gdcheck & 8){print <<<EOT
-->
	<tr><td align="center">認證碼︰</td><td><img src="ck.php?nowtime=1" align="absmiddle" onclick="this.src='ck.php?nowtime=' + new Date().getTime();" style="cursor:pointer;" /><br /><input class="input" type="text" name="gdcode" size="8" /></td></tr>
<!--
EOT;
}if($msgq && $db_question){
$qkey = array_rand($db_question);
print <<<EOT
-->
	<tr><td align="center">驗證問題︰</td>
		<td><input class="input" type="text" name="qanswer" /><input type="hidden" name="qkey" value="$qkey" /> 問題︰$db_question[$qkey]</td></tr>
<!--
EOT;
}print <<<EOT
-->
	<tr><td align="center">內容︰</td><td><textarea name="atc_content" onkeydown="ajax.quickpost(event,this.form)" rows="8" style="width:97%"></textarea></td></tr>
	</tbody>
</table>
<ul><li style="text-align:center;padding:4px 0;"><input type="button" class="btn" name="ajaxsubmit" onclick="ajax.submit(this.form);" value="提 交" /></li></ul>
</form>
</div>
<!--
EOT;
}elseif($action=='usetool'){print <<<EOT
-->
<div class="bor">
<table width="100%" cellspacing="0" cellpadding="5">
<tr><th colspan="2" class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>道具中心</th></tr>
<!--
EOT;
foreach($tooldb as $key=>$value){print <<<EOT
-->
<tr>
	<td><a style="cursor:pointer" onclick="usetool('{$value[0][id]}')" title="{$value[0][descrip]}">{$value[0][name]}({$value[0][nums]})</a></td>
	<td>
<!--
EOT;
if($value[1][name]){print <<<EOT
-->
		<a style="cursor:pointer" onclick="usetool('{$value[1][id]}')" title="{$value[1][descrip]}">{$value[1][name]}({$value[1][nums]})</a>
<!--
EOT;
}print <<<EOT
-->
	</td>
</tr>
<!--
EOT;
}print <<<EOT
-->
</table>
</div>
<!--
EOT;
}elseif($action=='usertool'){print <<<EOT
-->
<div class="bor">
<table width="100%" cellspacing="0" cellpadding="5">
<tr><th colspan="2" class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>道具中心</th></tr>
<!--
EOT;
foreach($tooldb as $key=>$value){print <<<EOT
-->
<tr>
	<td><a style="cursor:pointer" onclick="usertool('$uid','{$value[0][id]}')" title="{$value[0][descrip]}">{$value[0][name]}({$value[0][nums]})</a></td>
	<td>
<!--
EOT;
if($value[1][name]){print <<<EOT
-->
		<a style="cursor:pointer" onclick="usertool('$uid','{$value[1][id]}')" title="{$value[1][descrip]}">{$value[1][name]}({$value[1][nums]})</a>
<!--
EOT;
}print <<<EOT
-->
	</td>
</tr>
<!--
EOT;
}print <<<EOT
-->
</table>
</div>
<!--
EOT;
}elseif($action=='extend'){
if($type=='pwcode'){print <<<EOT
-->
<div style="padding:1px;">
<!--
EOT;
foreach($code as $key=>$value){print <<<EOT
-->
<span class="button" id="wy_$value[name]" title="$value[title]" onmouseover="this.className='button buttonHover'" onmouseout="this.className='button'" onmousedown="this.className='button buttonActive'" onclick="this.className='button';upcode(this.id,'$value[param]');"><img style="width:20px;height:20px" src="$imgpath/post/c_editor/$value[icon]" /><span style="display:none">$value[descrip]</span></span>
<!--
EOT;
}print <<<EOT
-->
</div>
<!--
EOT;
}else{
if(!$setform){print <<<EOT
-->
<ul style="width:80px" class="tac f12">
<!--
EOT;
foreach($setformdb as $key=>$value){print <<<EOT
-->
<li><a href="javascript:onclick=showform('$value[id]')">$value[name]</a></li>
<!--
EOT;
}print <<<EOT
-->
</ul>
<!--
EOT;
}else{print <<<EOT
-->
<div class="bor">
<table width="100%" cellspacing="0" cellpadding="5" id="formstyle">
<tr><th colspan="2" class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();read.obj=null;"><img src="$imgpath/close.gif" /></span>$setform[name]</th></tr>
<!--
EOT;
foreach($setform[value] as $k=>$v){print <<<EOT
-->
<tr><td align="center">$v[0]</td><td><!--
EOT;
if($v[1]){
$s=explode(',',$v[1]);
print <<<EOT
--><select><!--
EOT;
foreach($s as $k1=>$v1){print <<<EOT
--><option value="$v1">$v1</option><!--
EOT;
}print <<<EOT
--></select><!--
EOT;
}else{print <<<EOT
--><input type="text" class="input"/><!--
EOT;
}print <<<EOT
--></td></tr>
<!--
EOT;
}print <<<EOT
-->
</table>
<ul><li style="text-align:center;padding:4px 0;"><input type="button" class="btn" value="提 交" onclick="insertform('$setform[name]');" align="absmiddle"> <input type="button" class="btn" value="取消" onclick="closep();read.obj=null;"></li></ul>
</div>
<!--
EOT;
}}}elseif($action=='sharelink'){print <<<EOT
-->
<div class="bor">
<form action="pw_ajax.php?action=$action" method="post" onsubmit="return false;">
<input type="hidden" name="verify" value="$verifyhash" />
<table width="100%" cellspacing="0" cellpadding="5">
<tr><th colspan="2" class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>友情鏈接申請</th></tr>
<tr><td width="24%" align="center">站點名稱</td>
<td><input size="30" name="linkname" class="input" style="margin-top:6px;"></td></tr>
<tr><td align="center">站點URL</td>
<td><input size="30" name="linkurl" class="input"></td></tr>
<tr><td align="center">站點說明</td>
<td><input size="30" name="linkdescrip" class="input"></td></tr>
<tr><td align="center">站點LOGO</td>
<td><input size="30" name="linklogo" class="input"></td></tr>
</table>
<input type="hidden" name="step" value="2" />
<ul><li style="text-align:center;padding:4px 0;"><input type="button" class="btn" onclick="ajax.submit(this.form);" value="提 交" /></li></ul></form>
</div>
<!--
EOT;
}elseif($action=='newrp'){print <<<EOT
-->
<div class="bor">
<table width="100%" cellspacing="0" cellpadding="5">
<tr><th colspan="4" class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>回復提醒</th></tr>
<tr class="tr2 tac" >
	<td width="20%">版塊名稱</td>
	<td>標題</td>
	<td width="20%">回復時間</td>
	<td width="6%">刪</td>
</tr>
<!--
EOT;
foreach($replydb as $key=>$val){print <<<EOT
-->
<tr class="tr3 tac">
	<td><a href="thread.php?fid=$val[fid]" target="_blank">$val[fname]</a></td>
	<td class="tal"><a href="read.php?tid=$val[tid]" target="_blank">$val[subject]</a></div></td>
	<td><a>$val[lastpost]</a></td>
	<td><img src="$imgpath/post/c_editor/del.gif" style="cursor:pointer" onclick="ajax.send('pw_ajax.php','action=delnewrp&tid=$val[tid]',newrp);" /></td>
</tr>
<!--
EOT;
}print <<<EOT
-->
</table>
</div>
<!--
EOT;
}elseif($action=='showface'){print <<<EOT
-->
<div class="bor">
<table width="100%" cellspacing="0" cellpadding="5">
<tr><th colspan="2" class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>頭像列表</th></tr>
<tr><td style="background:#ffffff">$imgselect</td></tr>
<!--
EOT;
if($num>$db_perpage){print <<<EOT
-->
<tr><td><a class="fr" onclick="sendmsg('pw_ajax.php','action=showface&page=$next_page','profile');" style="cursor:pointer">下一頁</a><a onclick="sendmsg('pw_ajax.php','action=showface&page=$pre_page','profile');" style="cursor:pointer">上一頁</a></td></tr>
<!--
EOT;
}print <<<EOT
-->
</table>
</div>
<!--
EOT;
}elseif($action=='modify'){print <<<EOT
-->
<div class="bor">
<form action="ajax.php?action=$action" method="post" onsubmit="return false;">
<input type="hidden" name="verify" value="$verifyhash" />
<table width="100%" cellspacing="0" cellpadding="5">
	<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>編輯帖子 <span style="color:#FA891B">(按住Ctrl點擊直接進入高級模式)</span></th></tr>
	<tr><td width="15%" align="center" style="padding:5px 0">作者:</td><td>$atcdb[author]</td></tr>
	<tr><td align="center">標題:</td><td><input class="input" type="text" name="atc_title" size="65" value="$atc_title" /></td></tr>
<!--
EOT;
if(($db_gdcheck & 4) && $winddb['postnum'] < $db_postgd){print <<<EOT
-->
	<tbody><tr><td align="center">認證碼︰</td>
		<td><img src="ck.php?nowtime=1" align="absmiddle" onclick="this.src='ck.php?nowtime=' + new Date().getTime();" style="cursor:pointer;" /><br /><input class="input" type="text" name="gdcode" size="6" tabindex="2" maxLength="4" /></td></tr></tbody>
<!--
EOT;
}if($winddb['postnum'] < $postq && $db_question){
$qkey = array_rand($db_question);
print <<<EOT
-->
	<tbody><tr><td align="center">驗證問題︰</td>
		<td><input class="input" type="text" name="qanswer" /><input type="hidden" name="qkey" value="$qkey" /> 問題︰$db_question[$qkey]</td></tr></tbody>
<!--
EOT;
}print <<<EOT
-->
	<tr><td align="center">內容︰</td><td>
		<textarea name="atc_content" onkeydown="ajax.quickpost(event,this.form)" style="width:420px;height:135px">$atc_content</textarea>
	</td></td></tr>
</table>
<input type="hidden" name="step" value="2" />
<input type="hidden" name="fid" value="$fid" />
<input type="hidden" name="tid" value="$tid" />
<input type="hidden" name="pid" value="$pid" />
<input type="hidden" value="$article" name="article" />
<input type="hidden" value="1" name="atc_convert" />
<ul><li style="text-align:center;padding:4px 0;"><input type="button" class="btn" name="ajaxsubmit" onclick="ajax.submit(this.form,edited);" value=" 提 交 " /> <input type="button" class="btn" value="進入高級模式" onclick="window.location.href='post.php?action=modify&fid=$fid&tid=$tid&pid=$pid&article=$article'" /></li></ul></form>
</div>
<!--
EOT;
}elseif($action=='quote'){print <<<EOT
-->
<div class="bor" style="width:400px">
<form action="post.php?" method="post">
<input type="hidden" name="verify" value="$verifyhash" />
<table cellspacing="0" cellpadding="5" width="100%">
	<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>編輯帖子 <span style="color:#FA891B">(按住Ctrl點擊直接進入高級模式)</span></th></tr>
	<tr><td width="15%" align="center" style="padding:5px 0">標題︰</td><td><input class="input" type="text" name="atc_title" value="$atc_title" size="60" /></td></tr>
<!--
EOT;
if(($db_gdcheck & 4) && $winddb['postnum'] < $db_postgd){print <<<EOT
-->
	<tbody><tr><td align="center">認證碼︰</td>
		<td><img src="ck.php?nowtime=1" align="absmiddle" onclick="this.src='ck.php?nowtime=' + new Date().getTime();" style="cursor:pointer;" /><br /><input class="input" type="text" name="gdcode" size="6" tabindex="2" maxLength="4" /></td></tr></tbody>
<!--
EOT;
}if($winddb['postnum'] < $postq && $db_question){
$qkey = array_rand($db_question);
print <<<EOT
-->
	<tbody><tr><td align="center">驗證問題︰</td>
		<td><input class="input" type="text" name="qanswer" /><input type="hidden" name="qkey" value="$qkey" /> 問題︰$db_question[$qkey]</td></tr></tbody>
<!--
EOT;
}print <<<EOT
-->
	<tr><td align="center">內容︰</td><td>
		<textarea name="atc_content" onkeydown="ajax.quickpost(event,this.form)" style="width:96%;height:135px">$atc_content</textarea>
	</td></td></tr>
</table>
<input type="hidden" value="2" name="step" />
<input type="hidden" value="$pid" name="pid" />
<input type="hidden" value="$action" name="action" />
<input type="hidden" value="$fid" name="fid" />
<input type="hidden" value="$tid" name="tid" />
<input type="hidden" value="$article" name="article" />
<input type="hidden" value="1" name="atc_usesign" />
<input type="hidden" value="1" name="atc_convert" />
<ul><li style="text-align:center;padding:4px 0;"><input type="submit" name="ajaxsubmit" class="btn" value=" 提 交 " /> <input onclick="window.location.href='post.php?action=quote&fid=$fid&tid=$tid&pid=$pid&article=$article&page=$page'" type="button" class="btn" value="進入高級模式" /></li></ul></form>
</div>
<!--
EOT;
}elseif($action=='honor'){print <<<EOT
-->
<div class="bor">
<form action="pw_ajax.php?action=$action" method="post" onsubmit="return false;">
<input type="hidden" name="verify" value="$verifyhash" />
<input type="hidden" name="step" value="3" />
<table width="100%" cellspacing="0" cellpadding="5">
	<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>個性簽名編輯</th></tr>
	<tr><td align="center"><textarea name="content" style="width:95%;height:60px">{$winddb[honor]}</textarea></td></tr>
</table><ul><li style="text-align:center;padding:4px 0;"><input type="button" class="btn" onclick="ajax.submit(this.form,honor);" value=" 提 交 " /></li></ul></form>
</div>
<!--
EOT;
}elseif($action=='readlog'){print <<<EOT
-->
<div class="bor">
<table cellspacing="0" cellpadding="5">
<tr><th colspan="4" class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>最近瀏覽的帖子</th></tr>
<!--
EOT;
foreach($readb as $key=>$val){
$i=$key+1;
print <<<EOT
-->
<tr class="tr3 tac">
	<td>$i</td>
	<td class="tal"><a href="read.php?tid=$val[tid]" target="_blank">$val[subject]</a></div></td>
</tr>
<!--
EOT;
}print <<<EOT
-->
</table>
</div>
<!--
EOT;
}elseif($action=='threadlog'){print <<<EOT
-->
<div class="bor">
<table width="100%" cellspacing="0" cellpadding="5">
<tr><th colspan="4" class="h" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>最近瀏覽的版塊</th></tr><tr><td>
<ul>
<!--
EOT;
foreach($threaddb as $key=>$value){print <<<EOT
-->
<li><a href="thread.php?fid=$key">$value</a></li>
<!--
EOT;
}print <<<EOT
-->
</ul></td></tr></table>
</div>
<!--
EOT;
}elseif($action=='mgmode'){print <<<EOT
-->
<div id="mgmode" class="bor">
	<table width="100%" cellspacing="0" cellpadding="5">
		<tr><th class="h"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>可視化布局</th></tr>
<!--
EOT;
if($rightset['setforum']){print <<<EOT
-->
		<tr><td class="f_one"><a style="cursor:pointer" onclick="mf = new mgm.forder();" title="可視化修改版塊布局">版塊排序</a></td></tr>
		<tr><td class="f_one"><a style="cursor:pointer" onclick="mf = new mgm.fsetname();" title="點擊版塊名稱進行修改">版塊名稱修改</a></td></tr>
<!--
EOT;
}if($rightset['setstyles']){print <<<EOT
-->
		<tr><td class="f_one"><a style="cursor:pointer" onclick="mf = new mgm.style();" title="前台可視化修改風格">風格設置</a></td></tr>
<!--
EOT;
}print <<<EOT
-->
	</table>
</div>
<!--
EOT;
}elseif($action=='setstyle'){print <<<EOT
-->
<div class="bor">
<form action="pw_ajax.php?action=$action" method="post" onsubmit="return false;">
<input type="hidden" name="verify" value="$verifyhash" />
<table id="mgmode" width="100%" cellspacing="0" cellpadding="5">
	<tr><th class="h" colspan="3"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>風格設置</th></tr>
	<tr>
		<td style="padding:0 1em;" valign="top">
			<table>
			<tr class="tr5">
				<td colspan="2" style="padding:0 1em"><b>整體風格設置</b><tr>
			</tr>
			<tr>
				<td width="50%" style="padding:0 1em">表格寬度</td>
				<td><input class="input" type="text" name="set[tablewidth]" value="$tablewidth" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">頭部和尾部表格寬度</td>
				<td><input class="input" type="text" name="set[mtablewidth]" value="$mtablewidth" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">全局背景顏色</td>
				<td><input class="input" type="text" name="set[bgcolor]" value="$bgcolor" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">全局鏈接顏色</td>
				<td><input class="input" type="text" name="set[linkcolor]" value="$linkcolor" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">表格外邊框顏色</td>
				<td><input class="input" type="text" name="set[tablecolor]" value="$tablecolor" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">表格內邊框顏色</td>
				<td><input class="input" type="text" name="set[tdcolor]" value="$tdcolor" onblur="mf.setcss(this);" /></td>
			</tr>
			</table>
		</td>
		<td colspan="2" style="padding:0 1em">
			<table>
			<tr class="tr5"><td colspan="2" style="padding:0 1em"><b>表格樣式顏色設置</b></td></tr>
			<tr>
				<td style="padding:0 1em">表格標題欄顏色</td>
				<td><input class="input" type="text" name="set[headcolor]" value="$headcolor" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">表格標題欄下邊框顏色</td>
				<td><input class="input" type="text" name="set[headborder]" value="$headborder" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">標題欄主要字體鏈接顏色</td>
				<td><input class="input" type="text" name="set[headfontone]" value="$headfontone" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">{$ajax_headfonttwo}</td>
				<td><input class="input" type="text" name="set[headfonttwo]" value="$headfonttwo" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">表格副標題欄顏色</td>
				<td><input class="input" type="text" name="set[cbgcolor]" value="$cbgcolor" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">表格副標題欄下邊框顏色</td>
				<td><input class="input" type="text" name="set[cbgborder]" value="$cbgborder" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">表格副標題欄字體顏色</td>
				<td><input class="input" type="text" name="set[cbgfont]" value="$cbgfont" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">論壇列表顏色一</td>
				<td><input class="input" type="text" name="set[forumcolorone]" value="$forumcolorone" onblur="mf.setcss(this);" /></td>
			</tr>
			<tr>
				<td style="padding:0 1em">論壇列表顏色二</td>
				<td><input class="input" type="text" name="set[forumcolortwo]" value="$forumcolortwo" onblur="mf.setcss(this);" /></td>
			</tr>
			</table>
		</td>
	</tr>
</table>
<input type="hidden" name="step" value="2" />
<input type="hidden" name="setskin" value="$skin" />
<ul><li style="text-align:center;padding:4px 0;"><input type="button" class="btn" name="ajaxsubmit" onclick="ajax.submit(this.form,mf.submit);" value="提 交" /></li></ul></form>
</div>
<!--
EOT;
}elseif($action=='addfriend'){print <<<EOT
-->
<div class="bor">
<form action="pw_ajax.php?action=$action" method="post" onsubmit="return false;">
<input type="hidden" name="verify" value="$verifyhash" />
<input type="hidden" name="job" value="add" />
<input type="hidden" name="step" value="2" />
<input type="hidden" name="touid" value="$friend[uid]" />
<table id="mgmode" width="100%" cellspacing="0" cellpadding="5">
	<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>好友驗證信息</th></tr>
	<tr class="tr3">
		<td width="25%">請輸入驗證信息</td>
		<td><input class="input" type="text" name="checkmsg" size="30" /></td>
	</tr>
</table>
<ul><li style="text-align:center;padding:4px 0;"><input type="button" class="btn" name="ajaxsubmit" onclick="ajax.submit(this.form);" value="提 交" /></li></ul>
</form>
</div>
<!--
EOT;
}elseif ($action == 'pushto') {print<<<EOT
-->
<div class="bor">
	<table width="100%" cellspacing="0" cellpadding="5">
		<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>推送位置選擇</th></tr>
<!--
EOT;
$id=0;
foreach ($pushs as $key => $value){
if($id == '0'){print<<<EOT
-->
<tr>
<!--
EOT;
}$id++;print<<<EOT
-->
		<td><a onclick="return sendurl(this,1,'push')" href="mawhole.php?action=push&pushto=$value[id]&fid=$fid&seltid=$seltid" >$value[name]</a></td>
<!--
EOT;
if($id == 2){$id=0;print<<<EOT
-->
</tr>
<!--
EOT;
}}print<<<EOT
-->
	</table>
	</div>
<!--
EOT;
}elseif ($action == 'debate') {print<<<EOT
-->
<form action="pw_ajax.php?action=debate" method="post" onsubmit="return false;">
<div class="bor"><table width="100%" cellspacing="0" cellpadding="5">
	<tr><th class="h" colspan="2" style="cursor:move" onmousedown="read.move(event);"><span class="fr" style="margin-top:2px;cursor:pointer" onclick="closep();"><img src="$imgpath/close.gif" /></span>結束辯論，裁判點評</th></tr>
	<tr>
		<td>辯論結果︰</td>
		<td>
<!--
EOT;
if($debate[judge]==1){print<<<EOT
-->
正方勝(支持數︰ $debate[obvote] 辯手︰$debate[obposts])
<!--
EOT;
}elseif($debate[judge]==2){print<<<EOT
-->
平局
<!--
EOT;
}elseif($debate[judge]==3){print<<<EOT
-->
反方勝(支持數︰ $debate[revote] 辯手︰$debate[reposts])
<!--
EOT;
}else{print<<<EOT
-->
			<input class="input" type="radio" name="judge" value="1" />正方勝(支持數︰$debate[obvote]&nbsp;辯手︰$debate[obposts])<br />
			<input class="input" type="radio" name="judge" value="2" CHECKED/>平局<br />
			<input class="input" type="radio" name="judge" value="3" />反方勝(支持數︰$debate[revote]&nbsp;辯手︰$debate[reposts])
<!--
EOT;
}print<<<EOT
-->
		</td>
	</tr>
	<tr>
		<td>最佳辯手︰</td>
		<td>
<!--
EOT;
if($debate[debater]){print<<<EOT
-->
			<a href="u.php?username=$debate[debater]" target="_blank">$debate[debater]</a>
<!--
EOT;
}else{print<<<EOT
-->
			<input class="input" id="debater" type="text" name="debater">
			<select onChange="if(this.value)getObj('debater').value=this.value;">
			<option value="">推薦辯手(支持數)</option>
<!--
EOT;
foreach($debater as $val){print<<<EOT
-->
			<option value="$val[username]">$val[username]($val[vote])</option>
<!--
EOT;
}print<<<EOT
-->
			</select>
<!--
EOT;
}print<<<EOT
-->
		</td>
	</tr>
	<tr>
		<td>裁判點評:</td>
		<td><textarea class="input" name="umpirepoint" rows="5" cols="40">$debate[umpirepoint]</textarea></td>
	</tr>
</table>
<input type="hidden" name="step" value="2" />
<input type="hidden" name="do" value="judge" />
<input type="hidden" name="tid" value="$tid" />
<ul><li style="text-align:center;padding:4px 0;"><input type="button" class="btn" name="ajaxsubmit" onclick="ajax.submit(this.form);" value="提 交" /></li></ul>
</div></form>
<!--
EOT;
}?>
-->