 <!--<?php print <<<EOT
-->
<div class="bdbA">
	<div id="breadcrumbs">
		<a class="crumbs-item gray3" href="$db_bfn" title="$db_bbsname"><strong>$db_bbsname</strong></a><span class="crumbs-item current"><i> </i><strong>
<!--
EOT;
if($action=='del'){print <<<EOT
-->
				刪除文章
<!--
EOT;
}elseif($action=='move'){print <<<EOT
-->
				移動文章
<!--
EOT;
}elseif($action=='copy'){print <<<EOT
-->
				復制文章
<!--
EOT;
}elseif($action=='headtopic'){print <<<EOT
-->
				文章置頂操作
<!--
EOT;
}elseif($action=='digest'){print <<<EOT
-->
				文章精華操作
<!--
EOT;
}elseif($action=='type'){print <<<EOT
-->
				文章分類管理
<!--
EOT;
}elseif($action=='check'){print <<<EOT
-->
				文章審核管理
<!--
EOT;
}elseif($action=='lock'){print <<<EOT
-->
				文章鎖定操作
<!--
EOT;
}elseif($action=='pushtopic'){print <<<EOT
-->
				提前文章
<!--
EOT;
}elseif($action=='edit'){print <<<EOT
-->
				加亮文章標題操作
<!--
EOT;
}elseif($action=='unite'){print <<<EOT
-->
				主題合並操作
<!--
EOT;
}elseif($action=='downtopic'){print <<<EOT
-->
				壓帖操作
<!--
EOT;
}elseif($action == 'push'){print <<<EOT
-->
				推送操作
<!--
EOT;
}print<<<EOT
-->
		</strong></span>
	</div>
</div>
<style type="text/css">
.t{margin-top:8px;border:4px solid $forumcolortwo;}
.t table{border:2px solid $tablecolor;}
.t .h{font-weight:normal}
.t .tr3{line-height:25px;}
</style>
<form name="form1" method="post" action="mawhole.php?">
<input type="hidden" name="verify" value="$verifyhash" />
<input type="hidden" name="action" value="$action" />
<input type="hidden" name="fid"    value="$fid" />
<input type="hidden" name="step"   value="2" />
<!--
EOT;
if($threaddb){print <<<EOT
-->
<div class="t tac f_one" style="margin-top:8px">
<table width="100%" cellspacing="0" cellpadding="0" align="center">
	<tr>
		<td class="h" style="text-align:center" width="5%">ID</td>
		<td class="h" style="text-align:center">標題</td>
		<td class="h" style="text-align:center" width="15%">論壇</td>
		<td class="h" style="text-align:center" width="15%">作者</td>
		<td class="h" style="text-align:center" width="8%">回復</td>
		<td class="h" style="text-align:center" width="15%">發表時間</td>
	</tr>
<!--
EOT;
$id=0;
foreach($threaddb as $key=>$val){
$id++;
print <<<EOT
-->
	<tr class="tr3">
		<td><input type="checkbox" name="tidarray[]" value="$val[tid]" checked /></td>
		<th>
			<a href="read.php?tid=$val[tid]" target="_blank">$val[subject]</a>
		</th>
		<td>
			<a href="thread.php?fid=$val[fid]" target="_blank">{$forum[$val[fid]][name]}</a>
		</td>
		<td>
<!--
EOT;
if($val['anonymous'] && !$isGM && !pwRights($isBM,'viewhide')){ print <<<EOT
-->
			$db_anonymousname
<!--
EOT;
}else{ print <<<EOT
-->
			<a href="u.php?action=show&username=$val[author]" target="_blank">$val[author]</a>
<!--
EOT;
} print <<<EOT
-->
		</td>
		<td>$val[replies]</td>
		<td>$val[date]</td>
	</tr>
<!--
EOT;
}print <<<EOT
-->
</table></div>
<!--
EOT;
}print <<<EOT
-->
<div class="t f_one">
<table width="100%" cellspacing="0" cellpadding="0" align="center">
	<tr><td class="h">&nbsp;</td><td class="h">管理選項︰</td></tr>
<!--
EOT;
if($action=='headtopic'){print <<<EOT
-->
	<tr class="tr3">
		<th width="20%" style="text-align:right;">管理選項︰</th>
		<th>
			<input type="radio" name="topped" value="0" $topped_0 /> 取消置頂
			<input type="radio" name="topped" value="1" $topped_1 /> 置頂1
<!--
EOT;
if(!$isGM && pwRights($isBM,'topped')==2){print <<<EOT
-->
			<input type="radio" name="topped" value="2" $topped_2 /> 置頂2
<!--
EOT;
} elseif($isGM || pwRights($isBM,'topped')==3){print <<<EOT
-->
			<input type="radio" name="topped" value="2" $topped_2 /> 置頂2
			<input type="radio" name="topped" value="3" $topped_3 /> 置頂3
<!--
EOT;
}print <<<EOT
-->
		</th>
	</tr>
    <tr class="tr3"><th width="20%" style="text-align:right;">有效時間︰</th><th><input class="input" type="text" name="timelimit" size="4" /> 天</th></tr>
<!--
EOT;
}elseif($action=='digest'){print <<<EOT
-->
	<tr class="tr3">
	<th width="20%" style="text-align:right;">管理選項︰</th>
	<th>
		<input type="radio" name="digest" value="0" $digest_0 />取消精華
		<input type="radio" name="digest" value="1" $digest_1 />精華I
		<input type="radio" name="digest" value="2" $digest_2 />精華II
	</th>
	</tr>
<!--
EOT;
}elseif($action=='lock'){print <<<EOT
-->
	<tr class="tr3">
	<th width="20%" style="text-align:right;">管理選項︰</th>
	<th>
	<input type="radio" name="locked" value="0" $lock_0 />解除鎖定
	<input type="radio" name="locked" value="1" $lock_1 />鎖定
	<input type="radio" name="locked" value="2" $lock_2 />關閉
	</th>
	</tr>
<!--
EOT;
}elseif($action=='pushtopic'){print <<<EOT
-->
	<tr class="tr3">
		<th width="20%" style="text-align:right;">提前時間︰</th>
		<th><input type="text" class="input" name="pushtime" value="0" /> (時)</th>
	</tr>
	<tr class="tr3">
		<th style="text-align:right;">管理選項︰</th>
		<th>提前帖子</th>
	</tr>
<!--
EOT;
}elseif($action=='downtopic'){print <<<EOT
-->
	<tr class="tr3">
		<th width="20%" style="text-align:right;">壓後時間︰</th>
		<th><input type="text" class="input" name="timelimit" value="24" /> (時)</th>
	</tr>
	<tr class="tr3">
		<th style="text-align:right;">允許上浮︰</th>
		<th><input type="radio" name="ifpush" value="0" $lock_0 />是
		<input type="radio" name="ifpush" value="1" $lock_1 />否</th>
	</tr>
<!--
EOT;
}elseif($action=='type'){print <<<EOT
-->
	<tr class="tr3">
		<th width="20%" style="text-align:right;">選擇主題分類︰</th>
		<th><select name="type">
<!--
EOT;
foreach($t_typedb as $key=>$value){
if($value){print <<<EOT
-->
			<option value="$key">$value</option>
<!--
EOT;
}}print <<<EOT
-->
		</select>
		</th>
	</tr>
<!--
EOT;
}elseif($action=='move' || $action=='copy'){print <<<EOT
-->
	<tr class="tr3">
		<th width="20%" style="text-align:right;">選擇目的版塊︰</th>
		<th><select name="to_id" onchange="getThreadCates(this.value)">$forumcache
<!--
EOT;
if($forumadd){print <<<EOT
-->
			<option value="">>> 隱藏版塊</option>$forumadd
<!--
EOT;
}if(trim($cmscache)){print <<<EOT
-->
			<option value=""></option>
			<option value="">文章分類</option>$cmscache
<!--
EOT;
}print <<<EOT
-->
		</select></th>
	</tr>
	<tr class="tr3">
		<th width="20%" style="text-align:right;">主題分類︰</th>
		<th><div id="innerselect"><select name="to_threadcate" id="to_threadcate">
		<option value="">無主題分類</option>
		</select></div></th>
	</tr>
<script language="JavaScript">
var ttypedb = new Array();
ttypedb = $ttypedb;
function getThreadCates(fid){
	var fttypedb = new Array();
	if (ttypedb[fid] && ttypedb[fid] != 0) {
		var opftype = '<select name=\"to_threadcate\" id=\"to_threadcate\"><option value=\"\">不分類</option>';
	} else {
		var opftype = '<select name=\"to_threadcate\" id=\"to_threadcate\"><option value=\"\">無主題分類</option>';
	}
	fttypedb = ttypedb[fid].split("\t");
	for (var key in fttypedb){
		if (key == 0 || !fttypedb[key]){
		 continue;
		}
		opftype += '<option value=\"' + key + '\">' + fttypedb[key] + '</option>';
	}
	opftype += '</select>';
	getObj('innerselect').innerHTML = opftype;
}
</script>
<!--
EOT;
}elseif($action=='edit'){print <<<EOT
-->
<style type="text/css">
.pwnew span{float:left;margin-left:5px;}
.pwnew a{display:block;height:16px;width:16px;float:left;line-height:16px;border:1px solid $tdcolor;color:$linkcolor;cursor:pointer;}
.pwnew a:hover{border:1px solid $tablecolor;background:$forumcolortwo;color:$linkcolor;}
.pwnew .one,.pwnew .one:hover{border: 1px solid $headfontone;background:$headborder;color:$headfontone;}
.pwnew b:hover,.pwnew i:hover{text-decoration:none;}
.pwnew .two{background:url($imgpath/wind/menu-down.gif) right center no-repeat;width:30px;cursor:pointer;}
.pwnew .two:hover{background:$forumcolortwo url($imgpath/wind/menu-down.gif) right center no-repeat;text-decoration:none;}
</style>
<script type="text/javascript" language="JavaScript" src="js/color_picker.js"></script>
<script type="text/javascript">
function pickReback(color){
	getObj('color_show').style.backgroundColor = color;
}
function styleOnclick(e,obj){
	var objclass = e.className;
	var temp = objclass.split(' ');
	var newclass = '';
	for (var n=0; n<temp.length; n++){
		if (temp[n]=='one') {
			continue;
		}
		newclass += ' ' + temp[n];
	}
	if (objclass.match(/one/)) {
		e.className = newclass;
		getObj(obj).value = '';
	} else {
		e.className = newclass + ' one';
		getObj(obj).value = 1;
	}
}
function colorCancel(){
	getObj('color_show').style.backgroundColor='#FFFFFF';
	getObj('title1').value='';
}
</script>
	<tr class="tr3">
		<th style="text-align:right;">管理選項︰</th>
		<th>
			<div class="pwnew tac">
				<span title="粗體字"><b><a onclick="styleOnclick(this,'title2')" class="$stylename[1]">B</a></b></span>
				<span title="斜體字"><i><a onclick="styleOnclick(this,'title3')" class="$stylename[2]">I</a></i></span>
				<span title="下劃線"><u><a onclick="styleOnclick(this,'title4')" class="$stylename[3]">U</a></u></span>
				<span id="color_show" style="width:30px;margin-top:1px;border:1px solid $tablecolor;float:left;height:14px;background:$titlecolor;cursor:pointer;" title="點擊取消顏色" onclick="colorCancel()"></span>
				<span title="顏色選擇"><a class="two tal" onclick="showColorPicker(this,document.form1.title1,function(){pickReback(color_picker)})"><img src="$imgpath/pickcolor.gif"  /></a></span>
				<input id="title1" name="title1" type="hidden" value="$titlecolor" />
				<input id="title2" name="title2" type="hidden" value="{$titledetail[1]}" />
				<input id="title3" name="title3" type="hidden" value="{$titledetail[2]}" />
				<input id="title4" name="title4" type="hidden" value="{$titledetail[3]}" />
			</div>
		</th>
	</tr>
	<tr class="tr3"><th style="text-align:right;">有效時間︰</th><th><input class="input" type="text" name="timelimit" size="4" /> 天</th></tr>
<!--
EOT;
}elseif($action=='del'){print <<<EOT
-->
	<tr class="tr3">
		<th width="20%" style="text-align:right;">扣除積分︰</th>
		<th>
			<input type="radio" name="ifdel" value="1" checked />是
			<input type="radio" name="ifdel" value="0" />否
		</th>
	</tr>
<!--
EOT;
}elseif($action=='unite'){print <<<EOT
-->
	<tr class="tr3">
		<th width="20%" style="text-align:right;">合並帖子︰</th>
		<th>
<!--
EOT;
if($unitetype == 'from'){print <<<EOT
-->
		<input class="input" type="text" name="unitetid" size="15" /> (輸入來源帖子的tid,多個用“,”分開)
<!--
EOT;
} else{print <<<EOT
-->
		<input class="input" type="text" name="unitetid" size="15" /> (輸入目標帖子tid)
<!--
EOT;
}print <<<EOT
-->
		<input type="hidden" name="unitetype" value="$unitetype" />
		</th>
	</tr>
<!--
EOT;
}elseif($action == 'push'){print<<<EOT
-->
<tr class="tr3">
	<th width="20%" style="text-align:right;">推送位置︰</th>
	<th><b>{$pushs[$pushto][name]}</b></th>
</tr>
<!--
EOT;
if($params[title]){print<<<EOT
-->
<tr class="tr3">
	<th style="text-align:right;">標題:</th>
	<th><input type="text" class="input" name="subject" value="$subject" size="54" /></th>
</tr>
<!--
EOT;
}if($params[url]){print<<<EOT
-->
<tr class="tr3">
	<th style="text-align:right;">鏈接︰</th>
	<th><input type="text" class="input" name="url" value="$url" size="54"/></th>
</tr>
<!--
EOT;
}if($params[image]){print<<<EOT
-->
<!--
EOT;
if($imgdb){print<<<EOT
-->
<tr class="tr3">
	<th style="text-align:right;">圖片選擇</th>
	<th>
<!--
EOT;
$i = 0;
foreach($imgdb as $key => $value){
$checked = $i == 0 ? 'checked' : '';$i++;
print<<<EOT
-->
	<input type="radio" name="attachurl" value="$key" $checked><img src="$value" style="width:80px;height:80px;">
<!--
EOT;
}print<<<EOT
-->
	</th>
</tr>
<!--
EOT;
}print<<<EOT
-->
<tr class="tr3">
	<th width="20%" style="text-align:right;">自定義圖片︰</th>
	<th><input class="input" type="text" name="cimgurl" value="" size="54" /> ((如果設置自定義圖片地址，以自定義圖片為準))</th>
</tr>
<!--
EOT;
}if($params[value]){print<<<EOT
-->
<tr class="tr3">
	<th style="text-align:right;">摘要︰</th>
	<th><textarea name="content" value="$content" style="overflow:auto;width:300px;height:80px;" />$content</textarea></th>
</tr>
<!--
EOT;
}print <<<EOT
-->
<input type="hidden" name="tid" value="$tid" />
<input type="hidden" name="fid" value="$fid" />
<input type="hidden" name="oldsubject" value="$subject" />
<input type="hidden" name="postdate" value="$postdate" />
<input type="hidden" name="author" value="$author" />
<input type="hidden" name="pushto" value="$pushto" />
<!--
EOT;
}print <<<EOT
-->
	<tr class="tr3">
		<th width="20%" style="text-align:right;">短消息通知︰</th>
		<th>
			<input type="radio" name="ifmsg" value="1" checked />是
			<input type="radio" name="ifmsg" value="0" />否
		</th>
	</tr>
	<tr class="tr3">
		<th style="text-align:right;">操作原因︰</th>
		<th>			<textarea name="atc_content" rows="8" cols="80"></textarea>
<!--
EOT;
if($db_adminreason){print <<<EOT
-->
			<select name="" size="8" multiple onchange="this.form.atc_content.value=this.value">
				<option value="">自定義</option>
				<option value="">-------</option>
				$reason_sel
			</select>
<!--
EOT;
}print <<<EOT
-->

		</th>
	</tr>
	<tr><td></td><td style="padding:.5em 5em;">
<!--
EOT;
if(($action=='edit' || $action=='digest' || $action=='headtopic' || $action=='pushtopic') && $seltid){
${$action.'_N'}="disabled";
print <<<EOT
-->
<input type="radio" name="nextto" value="digest" $digest_N />精華
<input type="radio" name="nextto" value="headtopic" $headtopic_N />置頂
<input type="radio" name="nextto" value="edit" $edit_N />加亮
<input type="radio" name="nextto" value="pushtopic" $pushtopic_N />提前
<input type="radio" name="nextto" value="" checked />無
<!--
EOT;
} print <<<EOT
-->
&nbsp;<input class="btn" type="submit" name="Submit" value="提 交" style="margin-left:5px;" /><a class="btn3" type="button" onclick="javascript:history.go(-1)" />返 回</a>
	</td></tr>
</table></div>
</form>
<!--
EOT;
?>-->