<?php
if( !defined('ISDVBBS') ){
	header('HTTP/1.0 404 Not Found');
	exit;
}
?><!--<?php
global $_topicInfo,$groupsetting, $lang;
$boardid = $GLOBALS['boardid'];
$id = $GLOBALS['id'];
$replyid = $GLOBALS['replyid'];
$title =& $GLOBALS['title'];
$msgcontent = htmlspecialchars($GLOBALS['content']);
$doWealth = $GLOBALS['dowealth'];
$dousercp = $GLOBALS['dousercp'];
$douserep = $GLOBALS['douserep'];
$msg =& $GLOBALS['msg'];
$ismsg = $GLOBALS['ismsg'];
$topic = htmlspecialchars($GLOBALS['_topicInfo']['title']);
if( CanTopTopic_a() === false ){
	$checkbox1 = ' disabled ';
}
if( $_topicInfo['istop'] == 3 ){
	$checkbox1 = ' checked ';
}
if( $groupsetting[21] == 1 ){
	$boardtop = $lang['tpl.toptopic.str2'];
} else{
	$boardtop = '<font color="red">'.$lang['tpl.toptopic.str3'].'</font>';
}
if( $groupsetting[54] == 1 ){
	$areatop = $lang['tpl.toptopic.str2'];
} else{
	$areatop = '<font color="red">'.$lang['tpl.toptopic.str3'].'</font>';
}
if( $groupsetting[38] == 1 ){
	$alltop = $lang['tpl.toptopic.str2'];
} else{
	$alltop = '<font color="red">'.$lang['tpl.toptopic.str3'].'</font>';
}
print <<<EOT
-->
<!--固顶操作选项-->
<FORM METHOD=POST ACTION="admin_postings.php?action=p_do_placed_top_topic" name="frmAnnounce">
<input type="hidden" value="1" name="istopaction">
<input type="hidden" name="boardid" value="{$boardid}">
<input type="hidden" value="{$id}" name="id">
<input type="hidden" value="{$title}" name="title">
<input type="hidden" value="{$msgcontent}" name="content">
<input type="hidden" value="{$doWealth}" name="dowealth">
<input type="hidden" value="{$dousercp}" name="dousercp">
<input type="hidden" value="{$douserep}" name="douserep">
<input type="hidden" value="{$msg}" name="msg">
<input type="hidden" value="{$ismsg}" name="ismsg">
<table cellspacing="0" cellpadding="0" align="center" class="mainbox tableborder">
<tr>
<th height=24 colspan=2>{$lang['tpl.top.str1']}</th>
</tr>
<tr>
<td height=24 class=tablebody5 colspan=2>
{$lang['tpl.top.str2']}
<b>{$lang['tpl.top.str3']}</b>{$lang['tpl.top.str4']} <b>{$alltop}</b>  {$lang['tpl.top.str5']} <b>{$areatop}</b>  {$lang['tpl.top.str6']} <b>{$boardtop}</b>
</td>
</tr>
<tr>
<td height=24 class=tablebody6 width="50%">
<input type="checkbox" name="alltop" value="1" {$checkbox1} class="chkbox"> {$lang['tpl.top.str7']}
<input type="checkbox" name="movealltop" value="1" onclick="ChkSelected(frmAnnounce.elements['getboard[]'],this);" class="chkbox"> {$lang['tpl.top.str8']}
<BR><BR>
{$lang['tpl.top.str9']}<BR>
<select name="getboard[]" size="20" style="width:100%" multiple>
<!--{$boardselected}-->
<!--
EOT;
//有总固顶和区域固顶权限则显示所有版面列表
if( CanTopTopic_a() === true || CanTopTopic_m() === true ){
	print '--'.'>'.boardjumplist($boardid,$lang['tpl.top.str10']).'<!--';
} else{
	global $boardinfo;
	print <<<EOT
-->
<option value="{$boardinfo['boardid']}" selected>{$lang['tpl.toptopic.str1']}{$boardinfo['boardtype']}</option>
<!--
EOT;
}
print <<<EOT
-->
</select>
</td>
<td height=24 class=tablebody5 width="50%" valign=top>
<B><a href="dispbbs.php?boardid={$boardid}&id={$id}">{$topic}</a></B>
<BR><BR>
{$content}
</td>
</tr>
<tr>
<td height=24 class=tablebody5 align=center colspan=2>
<button type="submit" name=submit onMousemove="button_move(this)" onMouseout="button_out(this)">{$lang['tpl.top.str11']}</button></td>
</tr>
</table>
</FORM>
<SCRIPT LANGUAGE="JavaScript" charset="gbk">
<!--
//SELECT表单选取
function ChkSelected(Obj,ChkObj)
{
	if (Obj)
	{
		for (var i=0;i<Obj.length;i++){
			if (ChkObj.checked){
			Obj.options[i].selected=false;}
			else{
			Obj.options[i].selected=true;}
		}
	}
}
//-->
</SCRIPT>
<!--
EOT;
?>-->