ECSHOP购物车页面显示商品简单描述的修改教程

ECSHOP教程 来源: ECSHOP教程网www.ecshop119.com 时间:2013-11-17 ECSHOP教程分类:ECSHOP购买流程页修改

ecshop购物车页面显示商品简单描述的修改教程:

最近看到有朋友有这方面的需求,就整理了一下,写出来,供有同样需求的朋友备用

1、这里说的商品简单描述,不是商品的详细信息,而是后台编辑商品时在“其他信息”标签栏填写的那个“商品简单描述”,即goods_brief字段

2、修改lib_order.php文件的get_cart_goods()函数部分

 

$goods_thumb = $GLOBALS['db']->getOne("SELECT `goods_thumb` FROM " . $GLOBALS['ecs']->table('goods') . " WHERE `goods_id`='{$row['goods_id']}'");
$row['goods_thumb'] = get_image_path($row['goods_id'], $goods_thumb, true);


修改为

$goods_thumb = $GLOBALS['db']->getRow("SELECT `goods_thumb`,`goods_brief` FROM " . $GLOBALS['ecs']->table('goods') . " WHERE `goods_id`='{$row['goods_id']}'");
$row['goods_thumb'] = get_image_path($row['goods_id'], $goods_thumb['goods_thumb'], true);
$row['goods_brief']=$goods_thumb['goods_brief'];

3、在ECSHOP模板文件(flow.dwt)合适位置调用即可:
{$goods.goods_brief}

 

本文模板屋原创地址: https://www.ecshop119.com/ecshopjc-292.html
模板屋版权所有 © 转载时必须以链接形式注明出处!

微信联系我们
7x24小时服务
在线咨询
qqcodeback_top
温馨提示

确定取消
温馨提示

关闭