<?php if(!defined('EMLOG_ROOT')) {exit('error!');}?>
	<div class="browse">现在位置: <a title="返回首页" href="./">首页</a> &gt; 正文</div>
	<div id="main">
		<div id="content">
			<div class="primary">
					<h2 class="primary-title"><?php echo $log_title; ?></h2>
					<div class="archive_info">
						<span class="date"><?php echo gmdate('Y年n月j日', $date); ?></span>
						<span class="comment"> &#8260;<?php echo $comnum; ?>条评论</span>
						 &#8260; 被围观 <?php echo $views; ?>+
						<span class="edit"><?php if(ROLE == 'admin' || $author == UID): ?><a href="./?action=dellog&gid=<?php echo $logid;?>">删除</a><?php endif;?></span>
					</div>
					<?php echo $log_content; ?>
				<div class="scroll-top"><a href="javascript:scroll(0,0)">返回顶部</a></div>
			 </div>
	 		<div class="clear"></div>
</div>
        <!-- content -->
	</div>
    <!-- main-->
	<div class="comments">
		<div class="navi">共有<?php echo $comnum; ?>条评论：<?php echo $commentPageUrl;?></div>
	<div class="c">
		<?php foreach($commentStacks as $cid):
			$comment = $comments[$cid];
			$comment['poster'] = $comment['url'] ? '<a href="'.$comment['url'].'" target="_blank">'.$comment['poster'].'</a>' : $comment['poster'];
		?>
		<div class="l">
		<b><?php echo $comment['poster']; ?></b>
		<div class="info"><?php echo $comment['date']; ?> <a href="./?action=reply&cid=<?php echo $comment['cid'];?>">回复</a></div>
		<div class="comcont"><?php echo $comment['content']; ?></div>
		</div>
		<?php endforeach; ?>
	</div>
	<div class="t">发表评论：</div>
	<div class="c">
		<form method="post" action="./index.php?action=addcom&gid=<?php echo $logid; ?>">
		<?php if(ISLOGIN == true):?>
		当前已登录为：<b><?php echo $user_cache[UID]['name']; ?></b><br />
		<?php else: ?>
		昵称<br /><input type="text" name="comname" value="" /><br />
		邮件地址 (选填)<br /><input type="text" name="commail" value="" /><br />
		个人主页 (选填)<br /><input type="text" name="comurl" value="" /><br />
		<?php endif; ?>
		内容<br /><textarea name="comment" rows="10"></textarea><br />
		<?php echo $verifyCode; ?><br /><input type="submit" value="发表评论" />
		</form>
	</div>
	</div>