<?php  
require "../../Run.php";
require root_path.'/include/page.inc.php';

$mysql = new D('dd_html');
//获取文章列表     
$htmllist = $mysql->where(array('siteid'=>WAPID))->limit(slist($_GET['page'],15),15)->select();
	if($htmllist){
		$nums = 0;
		foreach( $htmllist as $value)
		{
		$div = $num++%2 == 0?'line1':'line2';
		$html.= '<div class="'.$div.'"><a href="mod.php?id='.$value['htmlid'].'">$dd_'.$value['title'].'</a>[<a href="mod.php?id='.$value['htmlid'].'">修改</a>]</div>';
		}
	}else{
	$html = '此栏目暂无记录';
	}
	echo head('标签管理');
	echo '<div class="title">';
	echo '<a href="add.php?">添加HTML标签</a>';
	echo '</div>';
	echo $html;
	$sql = "SELECT count(*) FROM html WHERE gro ='{$_GET['cid']}'";   
	$result = mysql_query($sql); 
	list($num) = mysql_fetch_row($result);
	$url = 'list.php?&';
	echo page($num,15,$url,NULL,'view');
?>
</div>
<div class="mylink"><a href="../wap_admin.php">返回上级</a><a href="../../index.php?">返回首页</a>
</div>
 <?php echo footer(1);?>
</body>
</html>