<?php
if( !defined('ISDVBBS') ){
	header('HTTP/1.0 404 Not Found');
	exit;
}
require_once INC_PATH.'dv_code.php';
global $_SERVER, $gettitle, $userinfo, $postbuyinfo,$imgurl,$forumuserinfo_spaceline,$show_user_fun_info;
$forumuserinfo_spaceline='<font color="#7AADC8"> & </font>';
//相关设置,一个个手工添加
$maxpostlen = $board_settings[49];
$piccheck = $board_settings[46];
$fontsize = $board_settings[80];
$postalipay = $board_settings[57];
$upostalipay = $fsetting['usertopic_alipay'];
$isspace = $fsetting['plus_blog'];
//如果要恢复行距设置请把下面一行屏蔽掉
$lineheight = $board_settings[81];
$indent = $board_settings[82];
$usertitle = $fsetting['usertitle'];
$menpai = $fsetting['ismenpai'];

if( $fsetting['plus_tools'] == 1 ){
} else{
}
$pos = strpos($TopicInfo['expression'],'|');
$mofaface = ( $pos !== false ? substr($TopicInfo['expression'],0,$pos) : '' );
$birthurl = $_DCACHE['forum_birth'][0];
$facpath = $_DCACHE['forum_postface'][0];
$parsedurl = parse_url(getRawUrl(true));
if (!empty($parsedurl['fragment'])) {
	$fragment = '#'.$parsedurl['fragment'];
} else {
	$fragment = '';
}
$styletitle = ShowCodeTitle($TopicInfo['topicmode'],$TopicInfo['topicfont']);
$ShowTopIcTitle = (!empty($styletitle))?'<em '.$styletitle.'>'.$TopicInfo['title'].'</em>': $TopicInfo['title'];

?>
<style type="text/css">
div.info{border-top : 1px dotted #cccccc; padding : 5px;line-height : normal; color : #c5c5c5;} 
font.showtools {color : white; background-color : #b88ffc; } 
.postlary2{border: 1px solid #7AADC8;   min-width :760px;margin : 0 auto;background-color:#e4e8ef;text-align : left; }
.postuserinfo{float:left;width:190px;text-indent:24px;}
.lockuser{height:30px;line-height:30px;width:150px;border: 1px solid #7AADC8;border-top:3px double #7AADC8;text-align : center;color:#00008B;margin :240px 0px 0px 10px;background-color : #e4e8ef;float:right;}
.vote{float:left;border-left: 1px solid #7AADC8;height:28px;}
.bodys{height:auto;width:97%;padding-right:0px; overflow-x: hidden;font-size:<?=$fontsize?>pt;line-height:<?=$lineheight?>px;text-indent:<?=$indent?>px;margin-top:10px;margin-bottom:50px;word-wrap: break-word;word-break: break-all;}
.tuser{padding-top:3px;line-height:30px;height:30px;}
.ouser{float:left;width :23px;text-indent:0px;margin:3px;}
.buser{float:left;width :15px;text-indent:0px;margin:5px;}
.cimg{margin:5px 0px 5px 0px;}
.tfloat{float:right;padding-right:5px;}
</style>
<div id="MagicFace" style="position:absolute;z-index : 99;visibility:hidden; "></div>
<script type="text/javascript">
function astro(birth)
{
	if (birth!='')
	{	var tmpstr;
	var bstr;
	var mm;
	var yy;
	var dd;
	var birthmonth;
	tmpstr=birth.split(' ')
	bstr=tmpstr[0]
	tmpstr=bstr.split('-')
	yy=(tmpstr[0]*1)
	mm=(tmpstr[1]*1)
	dd=(tmpstr[2]*1)
	switch(mm){
		case 1 :
		if(dd>=21){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][11]?> alt=<?=$lang['tpl.str1']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][10]?> alt=<?=$lang['tpl.str2']?>'+mm+'-'+dd+'>');}
		break;
		case 2 :
		if(dd>=20){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][12]?> alt=<?=$lang['tpl.str3']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][11]?> alt=<?=$lang['tpl.str1']?>'+mm+'-'+dd+'>');}
		break;
		case 3 :
		if(dd>=21){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][1]?> alt=<?=$lang['tpl.str4']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][12]?> alt=<?=$lang['tpl.str3']?>'+mm+'-'+dd+'>');}
		break;
		case 4 :
		if(dd>=21){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][2]?> alt=<?=$lang['tpl.str6']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][1]?> alt=<?=$lang['tpl.str4']?>'+mm+'-'+dd+'>');}
		break;
		case 5 :
		if(dd>=22){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][3]?> alt=<?=$lang['tpl.str8']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][2]?> alt=<?=$lang['tpl.str6']?>'+mm+'-'+dd+'>');}
		break;
		case 6 :
		if(dd>=22){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][4]?> alt=<?=$lang['tpl.str9']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][3]?> alt=<?=$lang['tpl.str8']?>'+mm+'-'+dd+'>');}
		break;
		case 7 :
		if(dd>=23){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][5]?> alt=<?=$lang['tpl.str10']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][4]?> alt=<?=$lang['tpl.str9']?>'+mm+'-'+dd+'>');}
		break;
		case 8 :
		if(dd>=24){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][6]?> alt=<?=$lang['tpl.str12']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][5]?> alt=<?=$lang['tpl.str10']?>'+mm+'-'+dd+'>');}
		break;
		case 9 :
		if(dd>=24){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][7]?> alt=<?=$lang['tpl.str13']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][6]?> alt=<?=$lang['tpl.str12']?>'+mm+'-'+dd+'>');}
		break;
		case 10 :
		if(dd>=24){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][8]?> alt=<?=$lang['tpl.str14']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][7]?> alt=<?=$lang['tpl.str13']?>'+mm+'-'+dd+'>');}
		break;
		case 11 :
		if(dd>=23){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][9]?> alt=<?=$lang['tpl.str15']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][8]?> alt=<?=$lang['tpl.str14']?>'+mm+'-'+dd+'>');}
		break;
		case 12 :
		if(dd>=22){return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][10]?> alt=<?=$lang['tpl.str2']?>'+mm+'-'+dd+'>');}
		else{return('<img src=<?=$birthurl.$_DCACHE['forum_birth'][9]?> alt=<?=$lang['tpl.str15']?>'+mm+'-'+dd+'>');}
		break;
		default : return('');
	}
	}else{return('');}
}
function MM_showHideLayers() { //v6.0

	var i,p,v,obj,args=MM_showHideLayers.arguments;
	obj=document.getElementById("MagicFace");
	for (i=0; i<(args.length-2); i+=3) if (obj) { v=args[i+2];
	if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
	obj.visibility=v; }
}
function DispMagicEmot(MagicID,H,W){
	MagicFaceUrl = "dv_plus/tools/magicface/swf/" + MagicID + ".swf";
	document.getElementById("MagicFace").innerHTML = '<OBJECT codeBase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=4,0,2,0" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="' + W + '" height="' + H + '"><PARAM NAME=movie VALUE="'+ MagicFaceUrl +'"><param name=menu value=false><PARAM NAME=quality VALUE=high><PARAM NAME=play VALUE=false><param name="wmode" value="transparent"><embed src="' + MagicFaceUrl +'" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="' + W + '" height="' + H + '"></embed>';
	document.getElementById("MagicFace").style.top = '250px';
	document.getElementById("MagicFace").style.left = '250px';
	document.getElementById("MagicFace").style.visibility = 'visible';
	MagicID += Math.random();
	setTimeout("MM_showHideLayers('MagicFace','','hidden')",5000);
	NowMeID = MagicID;
}
function LoadMagicEmot(MagicID,topicid){
	var cookiesstr=readCookie('mofaface_'+ topicid);
	if (cookiesstr ==null){
		createCookie('mofaface_'+ topicid,MagicID,365)
		DispMagicEmot(MagicID,350,500)
	}
}

</script>
<div class="mainbox notice">
	<?
	$savvy_action=($userid==0?"nologin":(Return_Userdono()===true?"nodone":""));
	?>
	<A HREF="savvypost.php?action=<?=$savvy_action?>&boardid=<?=$GLOBALS['boardid']?>" class="menu_quiz_a ask_savvy_a" onMouseOver="this.className='menu_quiz_hover ask_savvy_a'" onMouseOut="this.className='menu_quiz_a ask_savvy_a'"><?=$lang['list.tpl.str79']?></A>
</div>


<?
global $quest_gettitle,$bestanswer;
$quest_gettitle=$ShowTopIcTitle;
if( is_array($_PostResults) ){
	$position = 0;
	global $userinfo, $TrueMaster;
	if (1 == $board_settings[68]) {
		$userinfo['cananony'] = 1;
	}
	$userinfo['truemaster'] = $TrueMaster;
	$isBuyUser = ((!empty($membername) AND is_array($postbuyusers)) ? in_array($membername,$postbuyusers) : false );
	$bodystyle = 'tablebody2';

	$is_first=true;
	foreach( $_PostResults as $result ){
		//帖间随机广告
		if($forum_ads[12] && $ScriptName == 'savvy_dispbbs.php') {
			$dispbbs_ads = explode("\r\n", $forum_ads[13]);
			$num = count($dispbbs_ads) - 1;
			$num = rand(0, $num);
			$ads = $dispbbs_ads[$num];
		}
		$currUserID = intval($result['postuserid']);
		$lastpostid = $result['announceid'];
		$position++;
		list($firstIP,$secondIP)=explode('.',$result['ip']);
		$currUserInfo =& $postUserResult["{$currUserID}"];
		if ( $bodystyle == 'tablebody2' ){
			$bodystyle = 'tablebody1';
		}else{
			$bodystyle = 'tablebody2';
		}


		print '<table class="tablebox border" cellspacing="0" cellpadding="0"><tr>';
		if($is_first){
			$is_first=false;
			print '
			<base target="_blank" />
            <th colspan="2">'.$lang['tpl.str43'].$ShowTopIcTitle.'</th></tr><tr>';
		}


#---------左边用户信息-----------------
	$ShowUserInfo='';
	$ShowUserFace='';
	$ShowUserico='';
	#匿名用户 发帖图像
	if (1 == $userinfo['cananony'] AND 2 == $result['signflag'] AND true !== $userinfo['truemaster'] AND $userid != $currUserID )
	{
		$ShowUserInfo = $lang['tpl.str44']."(".$firstIP.$secondIP.")";
		$ShowUserFace = "<img src='{$imgurl}anyon.gif' width=111 height=111 border=0 />";
	}
	#客人 发帖图像
	elseif( $result['postuserid'] == 0 )
	{
		$ShowUserInfo = $lang['tpl.str45']."(".$firstIP.$secondIP."*.*)";
		$ShowUserFace = "<img src='{$imgurl}guest.gif' width=111 height=111 border=0 />";
	}
	#会员
	else
	{
		$currGrpSettings =& getCurrUserGrpSettings($currUserInfo['usergroupid']);
		$currUserInfo['namestyle'] = $currGrpSettings[58];
		list($tmp1,$tmp2) = explode($lang['tpl.str211'], $currUserInfo['namestyle']);
		if( $currUserInfo['usergroupid'] < 9 ){
			$currNameGlow = $nameglow[$currUserInfo['usergroupid']-1];
		} else{
			$currNameGlow = $_DCACHE['stylecss'][39];
		}

		$ShowUserInfo .= <<<EOT
		<div class="user_self_nav">
		  <ul>	
		  <li class="user2" onMouseOver="this.className='user1'" onMouseOut="this.className='user2'">{$tmp1}{$result['username']}{$tmp2}<img src="{$imgurl}down.gif" style="margin:5px;vertical-align:middle">
			  <div class="user_list">
EOT;
		
	$userim = explode('|||',$currUserInfo['userim']);
	if( $result['postuserid'] != 0 && ($userinfo['cananony'] != 1 || $result['signflag'] != 2 || $TrueMaster === true || $userid == $result['postuserid']) )
	{
		if( $upostalipay == 1 ){
			$ShowUserInfo .=  "<a href=\"https://www.alipay.com/payto:{$currUserInfo[useremail]}&partner=2088002048522272\" target=\"_blank\"><img alt=\"{$lang['tpl.str64']}{$result[username]}{$lang['tpl.str65']}\" border=\"0\" src=\"{$imgurl}alipay_s.gif\"  align=\"middle\"/></a><br /> \r\n";
		}
		if( $isspace == 1 ){
			$ShowUserInfo .= "<a href=\"space.php?UserID_{$result[postuserid]}.index.html\" title=\"{$lang['tpl.str66']}{$result[username]}{$lang['tpl.str67']}\" target=\"_blank\"><span><img src=\"{$imgurl}/space.gif\"></span>".$lang['disp.user.fun.info1']."</a><br /> \r\n";
		}
		if( $userid>0 && $userim[1] != '' && is_numeric($userim[1])){#发送QQ消息
			$ShowUserInfo .= "<a href=\"http://wpa.qq.com/msgrd?V=1&Uin={$userim[1]}&Site={$fsetting['forumname']}&Menu=yes\" title=\"{$lang['tpl.str68']}{$result[username]}\" target=\"_blank\"><span><img src=\"{$imgurl}/qq.gif\"></span>".$lang['disp.user.fun.info18']."</a><br /> \r\n";
		}
		elseif( empty($userid) && $userim[1] != '' && is_numeric($userim[1])){
			$ShowUserInfo .= "<a href=\"http://wpa.qq.com/msgrd?V=1&Uin={$userim[1]}&Site={$fsetting['forumname']}&Menu=yes\" title=\"{$lang['tpl.str68']}{$result[username]}\" target=\"_blank\"><span><img src=\"{$imgurl}/qq.gif\"></span>".$lang['disp.user.fun.info18']."</a><br /> \r\n";
		}
		if( $userid != 0 )
		{
			$username = urlencode($result['username']);
			$ShowUserInfo .= <<<EOT
			<a href="friendlist.php?action=addF&myFriend={$username}" target="_blank" alt="{$lang['tpl.str71']}{$result[username]}{$lang['tpl.str72']}"><span><img src="{$imgurl}/friend.gif"></span>{$lang['disp.user.fun.info14']}</a><br />
			<a href="dispuser.php?id={$result[postuserid]}" target="_blank" alt="{$lang['tpl.str73']}{$result[username]}{$lang['tpl.str74']}"><span><img src="{$imgurl}/profile.gif"></span>{$lang['disp.user.fun.info15']}</a><br /> 					
EOT;
			if( $currUserInfo['useremail'] != '' ){
				$ShowUserInfo .= "<a href=\"mailto:{$currUserInfo[useremail]}\"  alt=\"{$lang['tpl.str77']}{$result[username]}\"><span><img src=\"{$imgurl}/email.gif\"></span>E-Mail</a><br />\r\n";
			}
		}
		if( $userim[0] != '' ){
			$ShowUserInfo .= "<a href=\"{$userim[0]}\" target=\"_blank\" alt=\"{$lang['tpl.str78']}{$result[username]}{$lang['tpl.str79']}\"><span><img src=\"{$imgurl}/homepage.gif\"></span>".$lang['disp.user.fun.info17']."</a><br /> \r\n";
		}
		if( $userim[6] != '' ){
			$ShowUserInfo .= "<a href=\"http://service.51uc.com/user_info/show_user_info_base.shtml?UID={$userim[6]}\" title=\"{$result[username]}[{$userim[6]}]{$lang['tpl.str80']}\" target=\"_blank\"><span><img src=\"{$imgurl}/uc.gif\"></span>".$lang['disp.user.fun.info20']."</a>\r\n";
		}
	}
	$ShowUserInfo .= <<<EOT
		  </div>
	  </li>
	  </ul>
	</div>
EOT;
		#头像 在线或离线
		if (1 == $currUserInfo['userhidden']){
			if( $currUserInfo['usersex'] != 1 ){
				$ShowUserico =  "<img src=\"{$imgurl}offemale.gif\" alt=\"{$lang['tpl.str46']}\"/>\r\n";
			} else{
				$ShowUserico =  "<img src=\"{$imgurl}ofmale.gif\" alt=\"{$lang['tpl.str47']}\"/>\r\n";
			}
		} else{
			if( $currUserInfo['usersex'] != 1 ){
				$ShowUserico =  "<img src=\"{$imgurl}female.gif\" alt=\"{$lang['tpl.str48']}\"/>\r\n";
			} else{
				$ShowUserico =  "<img src=\"{$imgurl}male.gif\" alt=\"{$lang['tpl.str49']}\"/>\r\n";
			}
		}
		#生日
		if ( $currUserInfo['userbirthday'] != ''){
			$ShowUserBirthday ='';
			$ShowUserBirthday = "<div class=\"buser\"><script type=\"text/javascript\" language=\"javascript\">document.write (astro('{$currUserInfo[userbirthday]}'));</script></div>\r\n";
		}
		#用户头像图片
		$ShowUserFace ='';
		$userface = $currUserInfo['userface'];
		if( strpos($userface,'|') != false ){
			list(,$userfacePath) = explode('|',$userface);
			$ShowUserFace .= "<img src=\"{$userfacePath}\"  alt=\"\" width=\"{$currUserInfo[userwidth]}\" height=\"{$currUserInfo[userheight]}\" />\r\n";
			list($tmp1,$tmp2) = explode('|',$userface);
			if( $tmp1 != '0' ){
				$ShowUserFace .=  "<BR><a href=\"javascript:void(DispMagicEmot({$tmp1},350,500));\" target=\"_self\">{$lang['tpl.str50']}</a>\r\n";
			}
		} else{
			$ShowUserFace =  "<img  src=\"{$userface}\" width=\"{$currUserInfo[userwidth]}\" height=\"{$currUserInfo[userheight]}\"/>\r\n";
		}
		#用户等级图片
		$ShowUserStar = "<img class=\"cimg\" src=\"images/star/{$currUserInfo[titlepic]}\"/>\r\n";
		#用户勋章
		if($currUserInfo['userhonor']!=''){
			$ShowUserHonorpics='';
			if($currUserInfo['userhonor']!=''){
				if(strpos($currUserInfo['userhonor'],'|||')!==false){
					$tmpuserhonor=explode('|||',$currUserInfo['userhonor']);
					foreach ($tmpuserhonor as $tmpuserhonorarrs){			
						$h_title=honortitle($tmpuserhonorarrs);
						$ShowUserHonorpics.='<img src=dv_plus/honor/images/'.$tmpuserhonorarrs.' border=0 width=15 height=30 title='.$h_title.'>&nbsp;';
					}
				}
				else{			
					$h_title=honortitle($currUserInfo['userhonor']);
					$ShowUserHonorpics='<img src=dv_plus/honor/images/'.$currUserInfo['userhonor'].' border=0 width=15 height=30 title='.$h_title.'>';
				}
			}
			else{
				$ShowUserHonorpics='';
			}
		}
		#头衔
		if( $usertitle == 1 ){
			if( $currUserInfo['usertitle'] != '' ){
				$ShowUserTitle ='';
				$ShowUserTitle = "{$lang['tpl.str51']}{$currUserInfo['usertitle']}";
			}
		}
		#给用户发短信和用户发表帖子
		if( $userid > 0 ) {
			$ShowUserMessanger='';
			$ShowUserMessanger =  "<span><a href=\"messanger.php?action=new&touser={$username}\" title=\"{$lang['tpl.str69']}{$result[username]}{$lang['tpl.str70']}\" target=\"_parent\"><img src=\"{$imgurl}/message.gif\">{$lang['disp.user.fun.info13']}</a>&nbsp;&nbsp;<a href=\"query.php?stype=1&nsearch=3&keyword={$username}&boardid={$TopicInfo[boardid]}&searchdate=ALL\" target=\"_blank\" alt=\"{$lang['tpl.str75']}{$result[username]}{$lang['tpl.str214']}{$TopicInfo[boardtype]}{$lang['tpl.str76']}\"><img src=\"{$imgurl}/find.gif\">{$lang['disp.user.fun.info16']}</a></span>\r\n";
		}
		#等级
		$ShowUserClass = "{$lang['tpl.str52']}{$currUserInfo[userclass]}\r\n";
		#威望
		if( $currUserInfo['userpower'] != 0 ){
			$ShowUserPower = '';
			$ShowUserPower =  "{$lang['tpl.str53']}<font color=\"red\"><b>{$currUserInfo['userpower']}</b></font>\r\n";
		}
		#文章
		$ShowUserPostEp = "<span>{$lang['tpl.str54']}{$currUserInfo[userpost]}</span>\r\n";
		# 积分
		$ShowUserPostMONEY = "<span>{$lang['tpl.str55']}{$currUserInfo[userep]}</span>\r\n";
		#门派
		$groupname = $currUserInfo['usergroup'];
		if( $menpai == 1 && $currUserInfo['usergroup'] != '' ){
			$ShowUserGroup = '';
			$ShowUserGroup = "<span>{$lang['tpl.str56']}{$currUserInfo['usergroup']}</span>";
		}
		#注册日期
		$ShowUserJoindate = "{$lang['tpl.str58']}".gmdate("Y-m-d H:i:s",$currUserInfo['joindate']+getUserTimeZoneOffset());
		if (1== $userinfo['cananony'] AND 2 == $result['signflag']) {
			$ShowUserCananony = '';
			$ShowUserCananony = '<span><font color="ff0000">'.$lang['tpl.str212'].$lang['tpl.str59'].$lang['tpl.str213'].'</font></span>'."\r\n";
		}

	}#会员 end
#---------帖子右边部分-----------------
	$getpostdate = gmdate('Y-m-d H:i:s',$result['dateandtime']+getUserTimeZoneOffset()).'&nbsp;&nbsp;';
	#用户发帖IP和发帖时间
	$ShowUserPostIpDate = "<img src=\"{$imgurl}time.gif\"  border=\"0\" style=\"vertical-align:middle;\" />&nbsp;&nbsp;{$getpostdate}&nbsp;&nbsp;<img src=\"{$imgurl}ip.gif\" title=\"{$lang['disp.user.fun.info23']}\" alt=\"{$lang['disp.user.fun.info23']}\" border=\"0\" style=\"vertical-align:middle;\" />&nbsp;&nbsp;{$result['ip']}";
	#收录该帖到我的空间
	if( $isspace == 1 ){
		$ShowUserIsSpace = '';
		$ShowUserIsSpace =  "<a href=\"spacemanage.php?s=1&t=1&m=1&boardid={$TopicInfo[boardid]}&replyid={$result[announceid]}&id={$TopicInfo[topicid]}\" title=\"{$lang['tpl.str60']}\" target=\"_blank\"><img src=\"{$imgurl}spacefav.gif\"  border=\"0\" align=\"middle\" /></a> \r\n";
	}
	
switch($position){
				case 1: $ShowUserPosition = $lang['tpl.str61'];break;
				case 2: $ShowUserPosition = $lang['tpl.str61.1'];break;
				case 3: $ShowUserPosition = $lang['tpl.str61.2'];break;
				case 4: $ShowUserPosition = $lang['tpl.str61.3'];break;
				default: 
					$ShowUserPosition = "{$lang['tpl.str62']} <font color=\"red\">{$position}</font> {$lang['tpl.str63']}";
		}			
			
print <<<EOT
  <tr>
	<td class="infoleft leftcolor" valign="top" rowspan="4">
	   <a name="{$result['announceid']}"></a>
		<p class="username">{$ShowUserico}{$ShowUserInfo}</p>
		<p>{$ShowUserFace}</p>
		<p>{$ShowUserStar}</p>
		<p>{$ShowUserHonorpics}</p>
		<p>{$ShowUserTitle}</p>
		<p>{$ShowUserMessanger}</p>
		<p>{$ShowUserClass}</p>
		<p>{$ShowUserPower}</p>
		<p>{$ShowUserPostEp}</p>
		<p>{$ShowUserPostMONEY}</p>
		<p>{$ShowUserGroup}</p>
		<p>{$ShowUserJoindate}</p>
		<p>{$ShowUserCananony}</p>
	</td>
	<td class="usermenu">
		<em>{$ShowUserIsSpace} {$ShowUserPosition}</em>{$ShowUserPostIpDate}
	</td>
  </tr>
EOT
			
?>
</td>
<td class="<?=$bodystyle?>" width="*" valign="top" style="padding-left:10px;padding-right:10px; border-right:none;">
</div>
</div>

<div style="float:right;text-align:right;font-size:14px;color:green;">
<?
if($position==1){
	if(intval($TopicInfo['solve'])==1){
		print '<b>'.$lang['tpl.str215'].'</b>';
	}
	if(intval($TopicInfo['solve'])==2){
		print '<b>'.$lang['tpl.str222'].'</b>';
	}
}
if(intval($result['ask_solve'])==1){
	print '<img src="'.$imgurl.'icn_best.gif" border="0"><b>'.$lang['tpl.str225'].'</b>';
}
?>
</div>

<?
$checkinfo = '';
if( intval($result['isbest']) == 1 ){
	if( $groupsetting[41] != 1 ){
		$checkinfo = $lang['tpl.str81'];
	}
} else{
	if( $result['locktopic'] == 2 ){
		$checkinfo = $lang['tpl.str82'];
	} else{
		if( $currUserInfo['lockuser'] == 1 ){
			$checkinfo = $lang['tpl.str83'];
		} elseif( $currUserInfo['lockuser'] == 2 ){
			$checkinfo = $lang['tpl.str84'];
		} elseif( $result['locktopic'] == 3 ){
			$checkinfo = $lang['tpl.str85'];
		}
	}
}
if( $checkinfo != '' ){
	print "<div class=\"lockuser\">{$checkinfo}</div>\r\n";
}
if( $checkinfo == '' || $userinfo['truemaster'] == 1 || ( $boardmaster && $userinfo['usergroupid'] != 3 ) ){
	print "<br><div style=\"height:22px;\">\r\n<div style=\"float:left;\"><img src=\"images/topicface/{$result[expression]}\" alt=\"{$lang['tpl.str86']}\" align=\"middle\" /> <b>{$result['topic']}</b></div>";
	if( $result['parentid'] == 0 ){
		if( !empty($mofaface) ){
?>
<div style="float:right;margin-right:20px;"><a href="javascript:void(DispMagicEmot({$mofaface},350,500));" target="_self"><img src="dv_plus/tools/magicface/gif/{$mofaface}.gif" border="0"/><br /><?=$lang['tpl.str87']?></a></div>
<script type="text/javascript" language="javascript">
LoadMagicEmot('<?=$mofaface?>','<?=$TopicInfo['topicid']?>');
</script>

<?
		}
	}
	print "</div>\r\n<base target=\"_blank\" />\r\n<div class=\"bodys\" style=\"height:auto;\" onload=\"this.style.overflowX='auto';\">\r\n";
	if( $result['parentid'] == 0 && $TopicInfo['getmoneytype'] == 3 ){
		print '<fieldset style="border : 1px dotted #ccc;">';
		if( $TopicInfo['postuserid'] == $userid ){
			print "<legend style=\"text-indent:0px;\">{$lang['tpl.str88']} <b><font color=\"red\">{$TopicInfo['getmoney']}</font></b> {$lang['tpl.str89']}</legend>{$result['body']}";
		} else{
			if( true === $userinfo['truemaster']){
				print "<legend style=\"text-indent:0px;\">{$lang['tpl.str90']} <b><font color=\"red\">{$TopicInfo[getmoney]}</font></b> {$lang['tpl.str91']}</legend>{$result['body']}";
			} else{
				if( $isBuyUser === true ){
					print "<legend style=\"text-indent:0px;\">{$lang['tpl.str90']} <b><font color=\"red\">{$TopicInfo['getmoney']}</font></b> {$lang['tpl.str92']}</legend>{$result['body']}";
				} else{
					if( $userinfo['vipgroupuser'] == 1 && $postbuyinfo['notvipbuy'] == 1 ){
						print "<legend style=\"text-indent:0px;\">{$lang['tpl.str90']} <b><font color=\"red\">{$TopicInfo['getmoney']}</font></b> {$lang['tpl.str93']}</legend>{$result['body']}";
					} else{
						if( $userid != 0 && ($postbuyinfo['buyuser'] == ',,' || strpos($postbuyinfo['buyuser'],",{$membername},") !== false) ){
							print "<legend style=\"text-indent:0px;\">{$lang['tpl.str90']} <b><font color=\"red\">{$TopicInfo['getmoney']}</font></b> {$lang['tpl.str94']}</legend><input type=\"button\" value=\"{$lang['tpl.str95']}\" class=\"button\" onclick=\"location.href='buypost.php?action=buy&boardid={$TopicInfo['boardid']}&id={$TopicInfo['topicid']}&replyid={$result['announceid']}&posttable={$TopicInfo['posttable']}'\"/>";
						} else{
							print "<legend style=\"text-indent:0px;\">{$lang['tpl.str96']} <b><font color=\"red\">{$TopicInfo['getmoney']}</font></b> {$lang['tpl.str97']}</legend>";
							if( $userid != 0 ){
								print $lang['tpl.str98'];
							} else{
								print $lang['tpl.str99'];
							}
						}
					}
				}
			}
		}
		print '</fieldset>';
	} else {
		print func_script($result['body']);
		if(!empty($result['savvy_comment'])){
			print '<hr>'.$lang['tpl.str226'].$result['savvy_comment'];
		}
	}
	//相关提问begin
	if($position==1){
		if( !empty($arrRelatedTopic) && is_array($arrRelatedTopic) ){
			$urlTopic = htmlspecialchars(urlencode($TopicInfo['title']));
			print '<br><br>';
?>
					<div class="" style="margin-top : 20px;background:#eeeeee">
						<div style="float:left;"><?=$lang['tpl.str133']?></div>
					</div>
					<DIV class="savvy_corrask">
						<BLOCKQUOTE>
						<table cellpadding="0" cellspacing="0" align="center" width="100%">
							<tbody>
<?
foreach( $arrRelatedTopic as $currRelatedTopic ){
	$currRelatedTopic['lastposttime'] = gmdate('Y-m-d H:i:s', $currRelatedTopic['lastposttime']+getUserTimeZoneOffset());
?>
									<tr>
										<td class="tablebody1" height=23>&nbsp;&nbsp;<a href="savvy_dispbbs.php?boardid=<?=$currRelatedTopic['boardid']?>&id=<?=$currRelatedTopic['topicid']?>&page=<?=$page?>" target="_blank"><?=$currRelatedTopic['title']?></a></td>						
										<td class="tablebody2" align="center" width="45"><?=$currRelatedTopic['child']?></td>
									</tr>
<?
}
?>
							</tbody>
						</table>
<?
		}
?>
						</BLOCKQUOTE>
					</DIV>
<?
	}
	//相关提问end
	print "</div>\r\n<base target=\"_self\" />\r\n";
	if (canusersign($currUserInfo['usergroupid']) AND (1 == $result['signflag'])){
		if (!isset($currUserInfo['UserSignCache'])){
			$currUserInfo['UserSignCache'] = trim(Dv_SignUbbCode($currUserInfo['usersign'],$currUserInfo['usergroupid']));
		}
		$currusersign =& $currUserInfo['UserSignCache'];
	}
	else{
		$currusersign = '';
	}
	if ($currusersign) {
		print "<img src=\"{$imgurl}sigline.gif\" /><div style=\"padding-left:15px;\">{$currusersign}</div>\r\n";
	}
	else {
		print '<div style="padding-left:15px;clear:both;height:80px;text-valign:bottom;">&nbsp;</div>';
	}
}
$postinfo = '';
if( intval($result['isbest']) == 1 ){
	$postinfo = "<img src=\"{$imgurl}jing.gif\" border=\"0\" title=\"{$lang['tpl.str100']}\" align=\"middle\"/> ";
}
if( $result['isagree'] != '' && strpos($result['isagree'],'|') != false ){
	list($tmp1,$tmp2) = explode('|',$result['isagree']);
	if( !empty($tmp2) ){
		$postinfo = "<img src=\"{$imgurl}agree.gif\" border=\"0\" alt=\"{$lang['tpl.str101']}{$tmp2}{$lang['tpl.str102']}\" / > ";
	}
	if( !empty($tmp1) ){
		$postinfo = "<img src=\"{$imgurl}disagree.gif\" border=\"0\" alt=\"{$lang['tpl.str101']}{$tmp1}{$lang['tpl.str102']}\" / > ";
	}
}
if( intval($result['isupload']) == 2 || intval($result['isupload']) == 3 ){
	$postinfo = "<a href=\"wap.php?Action=readme\" target=\"_blank\" ><img src=\"{$imgurl}wap00.gif\" border=\"0\" alt=\"{$lang['tpl.str103']}\"/></a> ";
}
if( $TopicInfo['usetools'] != '' || $TopicInfo['getmoneytype'] != 0 ){
	$postinfo = "<img src=\"{$imgurl}mini_query.gif\" border=\"0\" alt=\"{$lang['tpl.str104']}\" onclick=\"openScript('viewinfo.php?t=2&action=View&posttable={$TopicInfo['posttable']}&boardid={$TopicInfo['boardid']}&id={$TopicInfo['topicid']}&replyid={$result['announceid']}',600,450)\" class=\"imgonclick\" /> ";
}
if( $result['parentid'] == 0 ){//call template TopicSendMoneyStr
	$tmp = intval($TopicInfo['getmoneytype']);
	if( $tmp == 1 ){
		$postinfo = "{$lang['tpl.str105']}<font color=\"red\">{$result['getmoney']}</font> {$lang['tpl.str106']}";
	}
	if( $tmp == 2 ){
		$postinfo = "{$lang['tpl.str107']}<font color=\"red\">{$TopicInfo['getmoney']}</font> {$lang['tpl.str106']}";
	}
	if( $tmp == 3 ){
		$postinfo = "{$lang['tpl.str108']}<font color=\"red\">{$TopicInfo['getmoney']}</font>{$lang['tpl.str106']}";
	}
	if( $tmp == 5 ){
		$postinfo = "{$lang['tpl.str105']}<font color=\"red\">{$result['getmoney']}</font>{$lang['tpl.str109']}";
	}
} else{//call template SendMoneyStr
	$tmp = intval($TopicInfo['getmoneytype']);
	if( ($tmp == 1 || $tmp == 5 ) && ( $TopicInfo['postuserid'] != $result['postuserid']) ){
		$postinfo = "{$lang['tpl.str110']}<font color=\"red\">{$result['getmoney']}</font>{$lang['tpl.str106']}";
	}
	if ($TopicInfo['postuserid'] == $userinfo['userid'] AND $result['postuserid'] != $userinfo['userid'] AND $tmp != 5 && $tmp == 1) {
		$postinfo = "<a href=\"buypost.php?action=send&posttable={$TopicInfo['posttable']}&boardid={$TopicInfo['boardid']}&id={$TopicInfo['topicid']}&replyid={$result['announceid']}&UserName={$result['username']}\" title=\"{$lang['tpl.str111']}{$result['username']}\" target=\"_blank\">{$lang['tpl.str112']}</a>";
	}
	if( $tmp == 2 ){
		$postinfo = "{$lang['tpl.str113']}<font color=\"red\">{$result['getmoney']}</font>{$lang['tpl.str106']}";
	}
}
if( $postinfo != '' ){
	print "<div class=\"info\">{$postinfo}</div>";
}
print "</td></tr>\r\n<tr><td class=\"{$bodystyle} ad_border\" ><div style=\"float:left;margin-left:5px;\">{$ads}</div><div style=\"float:right;margin-right:5px;\">\r\n";
if( $userid != 0 ){
	$strNoteActionMenu = '<div class="submenu" id="NoteActionMenu_'.$position.'" onmouseout="hidemenu(1);hidemenu(0);"><ul>';
	$strNoteActionMenu .= "<li><a href=\"topicother.php?t=6&boardid={$TopicInfo['boardid']}&id={$TopicInfo['topicid']}&replyid={$result['announceid']}\" title=\"{$lang['tpl.str116']}\">{$lang['tpl.str117']}</a></li>";
	if( $position != 1 || $TopicInfo['star'] != 1 ){
		if( $userid == $currUserID && $boardmaster == false ){
			if( $userinfo['candelmypost'] == 1 ){
				$strNoteActionMenu .= "<li><a href=\"admin_postings.php?action=p_delete_single_topic&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}&star={$TopicInfo['star']}&page={$GLOBALS['page']}&userid={$result['postuserid']}\">{$lang['tpl.str118']}</a></li>";
			}
		} else{
			if( $boardmaster === true ){
				$strNoteActionMenu .= "<li><a href=\"admin_postings.php?action=p_delete_single_topic&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}&star={$TopicInfo['star']}&page={$GLOBALS['page']}&userid={$result['postuserid']}\">{$lang['tpl.str118']}</a></li>";
			}
		}
	}
	if( $boardmaster === true ){
		$strNoteActionMenu .= "<li><a href=\"admin_postings.php?action=p_copy_topic&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}&star=star={$TopicInfo['star']}&userid=userid={$result['postuserid']}\">{$lang['tpl.str119']}</a></li>";
		if( intval($result['isbest']) == 0 ) {
			$strNoteActionMenu .= "<li><a href=\"admin_postings.php?action=p_set_best_topic&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}&star={$TopicInfo['star']}&page={$GLOBALS['page']}&userid={$result['postuserid']}\">{$lang['tpl.str120']}</a></li>";
		} else{
			$strNoteActionMenu .= "<li><a href=\"admin_postings.php?action=p_unset_best_topic&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}&star={$TopicInfo['star']}&page={$GLOBALS['page']}&userid={$result['postuserid']}\">{$lang['tpl.str121']}</a></li>";
		}
		if( $result['locktopic'] != 2 ){
			if( $result['locktopic'] == 3 ){
				$strNoteActionMenu .= "<li><a href=\"AccessTopic.php?action=unlock_topic&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}\">{$lang['tpl.str122']}</a></li>";
			} else{
				$strNoteActionMenu .= "<li><a href=\"admin_postings.php?action=p_shield_single_topic&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}&star={$TopicInfo['star']}&page={$GLOBALS['page']}&userid={$result['postuserid']}\">{$lang['tpl.str123']}</a></li>";
			}
		} else{
			$strNoteActionMenu .= "<li><a href=\"admin_postings.php?action=p_unshield_single_topic&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}&star={$TopicInfo['star']}&page={$GLOBALS['page']}&userid={$result['postuserid']}\">{$lang['tpl.str124']}</a></li>";
		}
		$strNoteActionMenu .= "<li><a href=\"admin_postings.php?action=p_reward_money&boardid={$TopicInfo['boardid']}&replyid={$result['announceid']}&id={$TopicInfo['topicid']}&star={$TopicInfo['star']}&page={$GLOBALS['page']}\" title=\"{$lang['tpl.str125']}\">{$lang['tpl.str126']}</a></li>";
	}
	if (1 == $GLOBALS['fsetting']['plus_tools']) {
		$strNoteActionMenu .= "<li><a title=\"{$lang['tpl.str127']}\" href=\"javascript:openScript('plus_tools_infosetting.php?action=0&amp;boardid={$TopicInfo['boardid']}&amp;topicid={$TopicInfo['topicid']}&amp;replyid={$result['announceid']}',500,400)\">{$lang['tpl.str128']}</a></li>";
	}
	$strNoteActionMenu .= '</ul></div>';
}
$getpostdate = gmdate('Y-m-d H:i:s',$result['dateandtime']+getUserTimeZoneOffset()).'&nbsp;&nbsp;';
echo '<div style="float:left;margin:0 0px 0 0;padding:2px;color:#808080;">'.$getpostdate.'</div>';
if( $boardmaster === true || ($TopicInfo['locktopic'] != 1 && $userinfo['canreply'] == 1) ){
	if( $result['postuserid'] == 0 ){
?>
				<a href="savvypost.php?action=re&boardid=<?=$TopicInfo['boardid']?>&replyid=<?=$result['announceid']?>&id=<?=$TopicInfo['topicid']?>&star=<?=$TopicInfo['star']?>&page=<?=$GLOBALS['page']?>&reply=true&guest=true"><img src="<?=$imgurl?>reply.gif" border="0" alt="<?=$lang['tpl.str129']?>" border="0" /></a> 
				<a href="savvypost.php?action=re&boardid=<?=$TopicInfo['boardid']?>&replyid=<?=$result['announceid']?>&id=<?=$TopicInfo['topicid']?>&star=<?=$TopicInfo['star']?>&page=<?=$GLOBALS['page']?>&guest=true"><img src="<?=$imgurl?>reply_a.gif" border="0" alt="<?=$lang['tpl.str130']?>" /></a> 
<?
	} else{
	}
}
global $moneystrtmp,$questionstrtmp,$noanswerstrtmp,$requestionstrtmp,$answerstrtmp;
if( $userid != 0){
	if($TopicInfo['solve']==0){
		if($userid==$TopicInfo['postuserid'] && $userid==$currUserID){
			if(intval($TopicInfo['solve'])!=2){//无满意答案后不显示
				$moneystrtmp='savvypost.php?action=medit&boardid='.$TopicInfo["boardid"].'&replyid='.$result["announceid"].'&id='.$TopicInfo["topicid"].'&star='.$TopicInfo["star"].'&page='.$GLOBALS["page"].'&reply=true';
				$questionstrtmp='savvypost.php?action=edit&boardid='.$TopicInfo["boardid"].'&replyid='.$result["announceid"].'&id='.$TopicInfo["topicid"].'&star='.$TopicInfo["star"].'&page='.$GLOBALS["page"].'&reply=true';
				$noanswerstrtmp='savvypost.php?action=noanswer&boardid='.$TopicInfo["boardid"].'&replyid='.$result["announceid"].'&id='.$TopicInfo["topicid"].'&star='.$TopicInfo["star"].'&page='.$GLOBALS["page"];
?>
						<a href="<?=$moneystrtmp?>"><img src="<?=$imgurl?>01.gif" alt="<?=$lang['tpl.str221']."\r\n".$lang['tpl.str220']?>"></a>
						<a href="<?=$questionstrtmp?>"><img src="<?=$imgurl?>05.gif" alt="<?=$lang['tpl.str221']."\r\n".$lang['tpl.str220']?>"></a>
						<a href="<?=$noanswerstrtmp?>"><img src="<?=$imgurl?>03.gif" alt="<?=$lang['tpl.str221']."\r\n".$lang['tpl.str220']?>"></a>
<?

			}
		}
		if( $userid == $currUserID){
			if( $groupsetting[10] == 1 ){
				if($position>1){
					global $reback;
					$reback=1;
					if(intval($TopicInfo['solve'])!=2){//无满意答案后不显示
						$requestionstrtmp='savvypost.php?action=edit&boardid='.$TopicInfo["boardid"].'&replyid='.$result["announceid"].'&id='.$TopicInfo["topicid"].'&star='.$TopicInfo["star"].'&page='.$GLOBALS["page"];
						?>
								<a href="<?=$requestionstrtmp?>" target="_self"><img src="<?=$imgurl?>05.gif"  alt="<?=$lang['tpl.str221']."\r\n".$lang['tpl.str220']?>"></a>
						<?
					}
				}
			}
		}
		else{
			if($userid==$TopicInfo['postuserid'] && $userid!=$currUserID){
				if(intval($TopicInfo['solve'])!=2){//无满意答案后不显示
					$answerstrtmp='savvypost.php?action=answer&boardid='.$TopicInfo["boardid"].'&replyid='.$result["announceid"].'&id='.$TopicInfo["topicid"].'&star='.$TopicInfo["star"].'&page='.$GLOBALS["page"];//设为满意答案
			?>
							<a href="<?=$answerstrtmp?>" target="_self"><img src="<?=$imgurl?>04.gif" border="0" alt="<?=$lang['tpl.str221']."\r\n".$lang['tpl.str220']?>"></a>
						

			<?
				}
			}
		}
	}
}
?>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#top"><img src="<?=$imgurl?>p_up.gif" border="0" alt="" /></a>
</td></tr></table>

<?
	}//end foreach

?>
<br/>

<?php
if( $TopicInfo['skin'] == 0 ) {
	$v = 1;
	if( $v == 1 ){

		$totalrec = intval($TopicInfo['child']) + 1;
		if ($fsetting['otherpagesize'] < 1) {
			$fsetting['otherpagesize'] = 20;
		}
		global $star,$board_settings;

		$pagesize = $board_settings[61];
$pagesize=2;
		($pagesize < 1) AND ($pagesize = 30);
		$pagecount = ceil((float)$totalrec / (float)$pagesize);
		
		$multipage = pagelist($totalrec,$pagesize,$star,"savvy_dispbbs.php?boardid={$TopicInfo['boardid']}&action={$action}&replyid={$TopicInfo['replyid']}&id={$TopicInfo['topicid']}&skin={$TopicInfo['skin']}",0,1000,'',1);

		$jumplist=boardjumplist($boardid);
		print <<<EOT
	 <div class="mainbox notice">
	<span>
	{$lang['list.tpl.str76']}
	&nbsp;<select name="BoardJumpList" id="BoardJumpList" onchange="if(this.options[this.selectedIndex].value!='')location='forum_savvy.php?boardid='+this.options[this.selectedIndex].value;" >
	{$lang['list.tpl.str76']}
	$jumplist
	</select>
	</span>
	<h1>
	{$multipage}
	</h1>

	 </div>
EOT;
} else{
	print '<span id="showpagelist"></span>';
}
}
?>

<?
if( $TopicInfo['skin'] == 1 ){
?>
<iframe style="border:0px;width:0px;height:0px;" src="loadtree.php?boardid=<?=$boardid?>&star=<?=$istar?>&page=<?=$GLOBALS['page']?>&replyid=<?=$replyid?>&id=<?=$AnnounceID?>&openid=<?=$lastpostid?>" name="hiddenframe"></iframe>
<div id="postlist" style="margin-top : 10px; margin-bottom : 10px; "></div>
<?
}
if( $userinfo['canreply'] == 1 ){
	if($TopicInfo['solve']==1){
		$buttuonshow=$lang['tpl.str223'];
	}
	else{
		$buttuonshow=$lang['tpl.str182'];
	}
	if($reback!=1){
		if($userid > 0){
			//登录才显示
			if($userid!=$TopicInfo['postuserid'] or $userid==$TopicInfo['postuserid'] && intval($TopicInfo['solve'])==1){
				//如果当前用户是提问的用户，并且问题已经设置为解决，则显示
				if(intval($TopicInfo['solve'])!=2){
					//无满意答案后不显示

?>
<base target="_self" />
<link rel="stylesheet" type="text/css" href="images/post/edit.css" />
<script src="templates/lang/<?=$GLOBALS['fsetting']['lang']?>/js/post/reply_sub.js" type="text/javascript"></script>
<script src="templates/lang/<?=$GLOBALS['fsetting']['lang']?>/js/post/post.js" type="text/javascript"></script>

<form id="Dvform" name="Dvform" action="savvy_savepost.php?action=sre&method=fastreply&boardid=<?=$TopicInfo['boardid']?>&star=<?=$GLOBALS['star']?>&page=<?=$GLOBALS['page']?><?=$fragment?>" onkeydown="ctlent();" onsubmit="return SetCheckData();" method="post">
<input type="hidden" id="Body" name="body" value="<?=$userinfo['postdata']?>" />
<input type="hidden" id="followup" name="followup" value="<?=$_PostResults[0]['announceid']?>" />
<input type="hidden" id="RootID" name="rootid" value="<?=$TopicInfo['topicid']?>" />
<input type="hidden" id="star" name="star" value="<?=$TopicInfo['star']?>" />
<input type="hidden" id="TotalUseTable" name="totalusetable" value="<?=$TopicInfo['posttable']?>" />
<input type="hidden" id="UserName" name="username" value="<?=$userinfo['username']?>" />
<input type="hidden" value="face1.gif" name="expression"/>
<div id="showReplyErr"></div>
<table class="tablebox border" cellspacing="0" cellpadding="0"><tr>
  <th colspan="5"><?=$buttuonshow.$quest_gettitle?></th></tr>
<?
print <<<EOT
 <tr>
    <td>
	<div class="quickpost_left">
EOT;
	echo '<div id="dv_ShowEmot"></div>
	<SCRIPT src="./js/dvShowEmot.js" type="text/JavaScript"></SCRIPT>
	<SCRIPT LANGUAGE="JavaScript">
	dv_ShowEmot("16","0","0","100%","190px","'.$lang['tpl.str.meot1'].'|||'.$lang['tpl.str.meot2'].'|||'.$lang['tpl.str.meot3'].'|||'.$lang['tpl.str.meot4'].'","'.$empath.'","'.str_replace('\n\t','',implode("|||", $_DCACHE['forum_emot'])).'");	
	</SCRIPT>
	';
print <<<EOT
	</div>
	<div class="quickpost_right">
	   <h1>
		<img src="images/post/fgcolor.gif" alt="{$lang['tpl.str143']}" class="icoover" onmouseover="this.className='icoovermouseover';" onmouseout="this.className='icoover';" onclick="Dvbbs_foreColor();this.className='icoonclick';"/>
		<img src="images/post/fbcolor.gif" alt="{$lang['tpl.str144']}" class="icoover" onmouseover="this.className='icoovermouseover';" onmouseout="this.className='icoover';" onclick="Dvbbs_backColor();this.className='icoonclick';"/>
		<img src="images/post/bold.gif" alt="{$lang['tpl.str145']}" class="icoover" onmouseover="this.className='icoovermouseover';" onmouseout="this.className='icoover';" onclick="FormatText('bold', '');this.className='icoonclick';"/>
		<img src="images/post/italic.gif" alt="{$lang['tpl.str146']}" class="icoover" onmouseover="this.className='icoovermouseover';" onmouseout="this.className='icoover';" onclick="FormatText('italic', '');this.className='icoonclick';"/>
		<img src="images/post/underline.gif" alt="{$lang['tpl.str147']}" class="icoover" onmouseover="this.className='icoovermouseover';" onmouseout="this.className='icoover';" onclick="FormatText('underline', '');this.className='icoonclick';"/>
		<img src="images/post/separator.gif" style="margin-top:4px;margin-right:4px;float:left;" alt=""/>
		<select class="Dvbbs_TBGen" id="FontSize" onchange="FormatText('fontsize',this[this.selectedIndex].value);">
		<option class="heading" selected="selected">{$lang['tpl.str176']}</option>
		<option value="1">1</option>
		<option value="2">2</option>
		<option value="3">3</option>
		<option value="4">4</option>
		<option value="5">5</option>
		<option value="6">6</option>
		<option value="7">7</option>
		</select>


EOT;
	#验证码
	if( $board_settings[46] == 1 ){
	$getcodehtml=get_cercode(100,24);print <<<EOT
		<b>{$lang['tpl.str141']}</b>
		  {$getcodehtml}
		<span id="getcodeinfo"></span>

	
EOT;
	}
print <<<EOT
	   </h1>
	   <p>
	      <iframe class="Dvbbs" id="Dvbbs_Composition" marginheight="5" marginwidth="5" width="99%" height="227" onblur="CheckCount('Body','total');"></iframe><span id="constr"></span>
	   </p>
	   <h1>
		<button onMousemove="button_move(this)" onMouseout="button_out(this)"  name="Submit"  type="Submit"> {$lang['tpl.str181']} </button>&nbsp;&nbsp;
		<button onMousemove="button_move(this)" onMouseout="button_out(this)" onclick="Gopreview()" name="Button"> {$lang['tpl.str184']} </button>&nbsp;&nbsp;
		<button onMousemove="button_move(this)" onMouseout="button_out(this)" onclick="ClearReset()" name="Clear"> {$lang['tpl.str185']} </button>
		{$lang['tpl.str186']}<input class="Dvbbs" disabled="disabled" maxLength="6" size="8" value="{$board_settings[49]}" name="total" /> {$lang['tpl.str187']}.&nbsp;&nbsp;
EOT;
	#签名 菜单部分
	if( $userid == 0 )
	{
		print '<input type="hidden" value="0" name="signflag" />';
	} 
	else
	{
		print '<b>'.$lang['tpl.str177'].'</b>&nbsp;&nbsp;<input type="radio" value="0" name="signflag"  class="radio"/>&nbsp;&nbsp;'.$lang['tpl.str178'].'&nbsp;&nbsp;<input type="radio" checked="checked" value="1" name="signflag" class="radio" />&nbsp;&nbsp;'.$lang['tpl.str179'];
		if( $userinfo['cananony'] == 1 )
		{
			print '&nbsp;&nbsp;<input type="radio" value="2" name="signflag" class="radio" />&nbsp;&nbsp;'.$lang['tpl.str180'];
		}
	}print <<<EOT
	   </h1>
	</div>
	</td>
  </tr>
EOT;
?>
</table>
</form>
<form name="preview" action="preview.php?boardid=<?=$TopicInfo['boardid']?>" method="post" target="preview_page">
<input type="hidden" name="Dvtitle" value="" /><input type="hidden" name="theBody" value="" /></form>
<script language="Javascript" type="text/javascript">
var Dvbbs_bIsIE5=document.all;
var Dvbbs_Mode = 3;
if (Dvbbs_bIsIE5){
	var IframeID=frames["Dvbbs_Composition"];
}
else
{
	var IframeID=document.getElementById("Dvbbs_Composition").contentWindow;
}

function Gopreview()
{
	document.preview.theBody.value=IframeID.document.body.innerHTML;
	var popupWin = window.open('', 'preview_page', 'scrollbars=yes,width=750,height=450');
	document.preview.submit()
}
Dvbbs_InitDocument('Body','gb2312');
</script>
<?
				}
				$postuserid = intval($TopicInfo['postuserid']);
				global $boardmaster;
			}
		}
	}
}
}

?>



<SCRIPT LANGUAGE="JavaScript">
var arr = new Array ('<?=$moneystrtmp?>','<?=$questionstrtmp?>','<?=$noanswerstrtmp?>','<?=$requestionstrtmp?>','<?=$answerstrtmp?>');
//数组1为：提高奖赏，数组2为：问题补充，数组3为：无满意答案、数组4为：答复者问题补充、数组5为：设为答案

function show_hidefilecode(file_name)
{
	return document.getElementById(file_name);//输入文件
}

  </SCRIPT>

<?php
if($forum_ads[2] == 1 || $forum_ads[7] == 1) {
?>
		<script language="javascript" src="templates/lang/<?=$GLOBALS['fsetting']['lang']?>/js/dv_adv.js" type="text/javascript"></script>
<?
}
if($forum_ads[2] == 1) {
?>
		<SCRIPT LANGUAGE="JavaScript">
		<!--
		move_ad('<?=$forum_ads[3]?>','<?=$forum_ads[4]?>','<?=$forum_ads[5]?>','<?=$forum_ads[6]?>');
		//-->
		</SCRIPT>
<?
}
if($forum_ads[7] == 1) {
?>
		<SCRIPT LANGUAGE="JavaScript">
		<!--
		fix_up_ad('<?=$forum_ads[8]?>','<?=$forum_ads[10]?>','<?=$forum_ads[11]?>','<?=$forum_ads[9]?>');
		//-->
		</SCRIPT>
<?
}
?>