将以下代码加入分类页面的模板,浏览时就可以显示当前分类的子分类:
{php} $str=''; $where=array(array('=','cate_ParentID',$category->ID)); $array=$zbp->GetCategoryList(null,$where,array('cate_Order'=>'ASC'),null,null); foreach ($array as $cate){ $str.='<li><a href="'.$cate->Url.'">'.$cate->Name.'</a></li>'; } echo $str; {/php}