方法一:
1.在flow.php中的
elseif ($_REQUEST['step'] == 'checkout')
中
$_SESSION['flow_consignee'] = $consignee;
前,插入
$sql = "SELECT concat( IFNULL(c.region_name, ' '), IFNULL(p.region_name, ''), IFNULL(t.region_name, ''), IFNULL(d.region_name, '')) AS region " ." FROM " . $ecs->table('region') . " c, " . $ecs->table('region') . " p, " . $ecs->table('region') . " t, " . $ecs->table('region') . " dWHERE c.`region_id`='".$consignee['country']."'AND p.`region_id`='".$consignee['province']."'AND t.`region_id`='".$consignee['city']."'AND d.`region_id`='".$consignee['district']."'";$consignee['region'] = $db->getOne($sql);
2.在flow.dwt中
<!-- {if $step eq "consignee"} -->
里面,将
<td bgcolor="#ffffff">{$consignee.address|escape} </td>
修改为
<td bgcolor="#ffffff">[{$consignee.region|escape}]{$consignee.address|escape} </td>
效果如:
http://www.ecy.cc/News/show/c/1/id/206.html
方法2
1.includes\lib_order.php,在
function get_consignee($user_id)
里的
return $arr;
前,添加以下语句
$sql = "select region_name from ".$GLOBALS['ecs']->table('region') . " where region_id in(".$arr['country'].",".$arr['province'].",". $arr['city'].",".$arr['district'].")";$address = $GLOBALS['db']->getAll($sql);foreach($address as $value){$arr['address1'] .= $value['region_name']." ";}
2.在flow.dwt中
<!-- {if $step eq "consignee"} -->
里面,将
<td bgcolor="#ffffff">{$consignee.address|escape} </td>
修改为
<td bgcolor="#ffffff">[{$consignee.region|escape}]{$consignee.address|escape} </td>
效果如下:
http://www.jb51.net/article/22577.htm
生活若剥去理想、梦想、幻想,那生命便只是一堆空架子