ecshop商品列表页显示每个商品的品牌


也想出现在这里?联系我们
AB模板王为您整理,在Ecshop商品列表页显示每个商品的品牌的修改方法1、首先修改 category.php 文件将$sql = SELECT g.goods_id, g.goods_name, g.goods_name_style, g

AB模板王为您整理,在Ecshop商品列表页显示每个商品的品牌的修改方法   1、首先修改 category.php 文件 将 $sql = 'SELECT g.goods_id, g.goods_name, g.goods_name_style, g.market_price, g.is_new, g.is_best, g.is_hot, g.shop_price AS org_price, ' .   修改为 $sql = 'SELECT g.goods_id, g.goods_name, b.brand_name , g.goods_name_style, g.market_price, g.is_new, g.is_best, g.is_hot, g.shop_price AS org_price, ' .   找到 "ON mp.goods_id = g.goods_id AND mp.user_rank = '$_SESSION[user_rank]' " .   在它下面增加一行 " LEFT JOIN  ". $GLOBALS['ecs']->table('brand') . " AS b on b.brand_id = g.brand_id " .   继续,找到 $arr[$row['goods_id']]['name']             = $row['goods_name'];   在它下边增加一行 $arr[$row['goods_id']]['brand_name']             = $row['brand_name'];   2、接下来打开模板库文件 /themes/default/library/goods_list.lbi 想在哪显示品牌就在哪加入代码 {$goods.brand_name}即可。
 

特别声明:以上内容(如有图片或视频亦包括在内)为本平台用户上传并发布,本平台仅提供信息存储服务。

开通vip