服务报价 | 域名主机 | 网络营销 | 软件工具| [加入收藏]
 热线电话: #
当前位置: 主页 > php教程 > ecshop教程 >

如何在ecshop后台定单详细里添加图片

时间:2011-01-06 12:05来源:未知 作者:最模板 点击:
如何在ecshop后台定单详细里添加图片 admin/order.php 在admin/order.php文件里添加了一字段 (g.goods_thumb,), /* 取得订单商品 */ $goods_list = array(); $goods_attr = array(); $sql = SELECT o.*, g.goods_number AS sto

如何在ecshop后台定单详细里添加图片

 admin/order.php

 
在admin/order.php文件里添加了一字段 (g.goods_thumb,), 
 
 
/* 取得订单商品 */
    $goods_list = array();
    $goods_attr = array();
    $sql = "SELECT o.*, g.goods_number AS storage, o.goods_attr, IFNULL(b.brand_name, '') AS brand_name " .
            "FROM " . $ecs->table('order_goods') . " AS o ".
            "LEFT JOIN " . $ecs->table('goods') . " AS g ON o.goods_id = g.goods_id " .
            "LEFT JOIN " . $ecs->table('brand') . " AS b ON g.brand_id = b.brand_id " .
            "WHERE o.order_id = '$order[order_id]' ";
    $res = $db->query($sql);
    while ($row = $db->fetchRow($res))
 
 
     $sql = "SELECT o.*, g.goods_thumb, g.goods_number AS storage, o.goods_attr, IFNULL
 
(b.brand_name, '') AS brand_name " .
            "FROM " . $ecs->table('order_goods') . " AS o ".
            "LEFT JOIN " . $ecs->table('goods') . " AS g ON o.goods_id = g.goods_id " .
            "LEFT JOIN " . $ecs->table('brand') . " AS b ON g.brand_id = b.brand_id " .
            "WHERE o.order_id = '$order[order_id]' ";
 
在g.goods_number前加g.goods_thumb,
 
 
最后 order_info.htm 引用
 
<img src="/{$goods.goods_thumb}" width="100"/>
 
(责任编辑:最模板)
顶一下
(0)
0%
踩一下
(0)
0%
------分隔线----------------------------
栏目列表
热点内容