<?php
	require substr(dirname(__FILE__),0,-5).'/include/common.inc.php';

	$sql="SELECT * FROM `".LA_PRE."type` WHERE `".LA_PRE."type`.`parentid`=".intval($typeid)." ORDER BY `".LA_PRE."type`.`orderby` ASC";

	$r=$db->fetch_all($sql);

	$str='';

	foreach($r as $_r)
	{
		$str.='<li><a href="'.$niubicms['site_url'].'post/index.php?typeid='.$_r['typeid'].'">'.$_r['name'].'</a></li>';
	}
	exit($str);


?>
