求救。如何在浏览历史以及销售排行中显示市场价格!???
2016-07-07 15:15 来源:www.chinab4c.com 作者:ecshop专家
求救。如何在浏览历史以及销售排行中显示市场价格!??? 紧急求救,希望好人帮忙谢谢!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! |
回答:
function insert_history() { $str = ''; if (!empty($_COOKIE['ECS']['history'])) { $where = db_create_in($_COOKIE['ECS']['history'], 'goods_id'); $sql= 'SELECT goods_id, goods_name,g.market_price, goods_thumb, shop_price FROM ' . $GLOBALS['ecs']->table('goods') . " WHERE $where AND is_on_sale = 1 AND is_alone_sale = 1 AND is_delete = 0"; $query = $GLOBALS['db']->query($sql); $res = array(); while ($row = $GLOBALS['db']->fetch_array($query)) { $goods['goods_id'] = $row['goods_id']; $goods['goods_name'] = $row['goods_name']; $goods['short_name'] = $GLOBALS['_CFG']['goods_name_length'] > 0 ? sub_str($row['goods_name'], $GLOBALS['_CFG']['goods_name_length']) : $row['goods_name']; $goods['goods_thumb'] = get_image_path($row['goods_id'], $row['goods_thumb'], true); $goods['market_price'] = price_format($row['market_price']); $goods['shop_price'] = price_format($row['shop_price']); $goods['url'] = build_uri('goods', array('gid'=>$row['goods_id']), $row['goods_name']); $str.='<ul class="clearfix"><li class="goodsimg"><a href="'.$goods['url'].'" target="_blank"><img src="'.$goods['goods_thumb'].'" alt="'.$goods['goods_name'].'" class="B_blue" /></a></li><li><a href="'.$goods['url'].'" target="_blank" title="'.$goods['goods_name'].'">'.$goods['short_name'].'</a><br />'.$GLOBALS['_LANG']['shop_price'].'<font class="f1">'.$goods['shop_price'].'</font><br />市场价:'.$goods['market_price'].'</li></ul>'; } $str .= '<ul id="clear_history"><a onclick="clear_history()">' . $GLOBALS['_LANG']['clear_history'] . '</a></ul>'; } return $str; } |
来记录一下 王子网球拍 |
最近更新
常用插件
- ecshop二次开发售后维修卡
插件介绍: 本插件是用于专门从事电子,信息,软件等售后服务关键比...
- ecshop供应商插件免费下载
ecshop供应商插件免费下载...
- ecshop选择下单时间插件
ecshop选择下单时间插件主要是根据不同的下单配送要求,在ecshop购物车...
- ecshop按分类筛选销售排行
ecshop按分类筛选销售排行...
- ecshop快递发货单打印商品
ecshop快递发货单打印商品信息,大家都知道ecshop快递单打印的时候,只能...
ecshop热门问答
ecshop热门资料
ecshop卸载uc
ecshop模特
ecshop报名
ecshop法登
ecshop后台流量分析
ecshop首页设置
ecshopwinsock
ecshop购物车商品选择结算
ecshop1065
ecshop担保支付
ecshopjuqery
ecshop模版
ecshop小菜
ecshop行货手机
ecshop整合问题
ecshop出租
ecshopPAYPAY
ecshop流量统计
ecshop建义
ecshop书签
ecshop商标
ecshop亮点
ecshop截至日期
ecshopdelete
ecshop改密码
ecshop批量导入导出
ecshop圖片
ecshop锁定
ecshop无法修改
ecshop改模板