destoon 会员中心分类从第二个分类显示

1970-01-01 08:00:00 62 0 来源:智智云
打开  include\post.func.php 找到get_category_select函数,添加   if(empty($v)) continue;
原始效果图:

最终效果图:

以下是整个函数的代码  

function get_category_select($title = '', $catid = 0, $moduleid = 1, $extend = '', $deep = 0, $cat_id = 1) {
global $_child;
$_child or $_child = array();
$parents = array();
if($catid) {
$r = DB::get_one("SELECT child,arrparentid FROM ".DT_PRE."category WHERe catid=$catid");
$parents = explode(',', $r['arrparentid']);
if($r['child']) $parents[] = $catid;
} else {
$parents[] = 0;
}
$select = '';
foreach($parents as $k=>$v) {
if(empty($v)) continue;
if($deep && $deep <= $k) break;
$select .= '
我们猜你喜欢
X

截屏,微信识别二维码

客服QQ:406784192

QQ号已复制,请打开微信添加咨询详情!