<?php
	!defined('DIRCMS_MANAGE') && exit('Access Denied!');
	if(!$module->roleid_check('yp',$_roleid))showmsg_nourl($lang['RETURN_NOPRI']);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>点评管理</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<link rel="stylesheet" type="text/css" href="admin/template/css/style.css" />
<script type="text/javascript" src="images/js/jquery.min.js"></script>
<script type="text/javascript" src="admin/template/js/admin.js"></script>
<script language="javascript" src="admin/template/js/css.js"></script>
</head>
<body>
<div id="wrap">
	<div class="tab">
		<ul>
			<li><a href="javascript:void(0);" class="on">点评管理</a></li>
		</ul>
	</div>
	<div class="main">
		<div class="search">
			<form action="?" method="get" name="search">
			<input type="hidden" name="mod" value="<?php echo isset($mod)?$mod:'yp';?>"> 
			<input type="hidden" name="file" value="<?php echo isset($file)?$file:'yp';?>"> 
			<input type="hidden" name="action" value="<?php echo isset($action)?$action:'comment';?>"> 
				<fieldset>
					<legend>搜索点评</legend>
						点评标题：
						<input type="text" name="k" size="35" value="<?php echo isset($k) && !empty($k)?htmlspecialchars(stripslashes($k)):'';?>" />
						<input type="submit" class="button" value="开始查找" />
				</fieldset>
			</form>
		</div>
		<table cellspacing="0" class="datalist" id="list" width="98%">
		<tr>			
			<th width="6%" class="firstcol">反选</th>
			<th width="50%">内容</th>
			<th width="19%">黄页名称</th>
			<th width="15%">发布时间</th>
			<th width="10%">发布IP</th>
		</tr>
		<form action="" method="post" name="myform">
		<input type="hidden" name="do_submit" value="1" />
		<?php if($result){foreach($result as $val){?>
		<tr>
		  <td width="6%" align="center"><input type="checkbox" checked="checked" name="id[]" value="<?php echo $val['id'];?>" class="checkbox" /></td>
		  <td width="50%" align="center"><?php echo strip_tags($val['content']);?></td>
		  <td width="19%" align="center"><?php echo $val['yp'];?></td>
			<td width="15%" align="center"><?php echo date('Y-m-d H:i:s',$val['addtime']);?></td>
			<td width="10%" align="center"><?php echo $val['ip'];?></td>
		</tr>
		<?php }?>
		<tr>
			<td align="center"><input type="checkbox" name="chkall2" value="1" checked="checked" class="checkbox" onclick="check_all(this)" /></td>
			<td colspan="4">
			<input type="button" onclick="if(confirm('确实要删除所选评论?'))this.form.submit();" class="submit" value="批量删除" />
			</td>
		</tr>
		</form>
		<?php }else{?>
		<tr><td colspan="5">目前尚未发布任何点评...</td></tr>	
		<?php }?>
		<tr><td colspan="5"><?php echo $yp->pagestring;?></td></tr>
		</table>
	</div>
</div>
</body>
</html>