商品分類樹需要始終顯示所有類別,默認的Ecshop的顯示方式為在當前產品頁面只顯示當前的產品所在的同級及下級分類,這就導致當點開某個產品或者子分類的時候全局的分類樹就不見了。其實修改的方法很簡單。只需要分別將goods.php和category.php文件中的
$smarty->assign('categories', get_categories_tree($goods['cat_id']));改為$smarty->assign('categories', get_categories_tree());
就可以。修改可以使用搜索進行。其中,在category.php中為$cat_array = get_categories_tree($c_id);
新聞熱點
疑難解答