有没有朋友帮看下,读取定单信息的问题。

2016-07-07 16:07 来源:www.chinab4c.com 作者:ecshop专家

<meta http-equiv="Content-Type" content="text/html; charset=gbk">
<?php
$con =mysql_connect("localhost","tb80","tb180123");

if (!$con)
{
die('Could not connect: ' .mysql_error());

}



mysql_select_db("tb180",$con);
mysql_query("set names gb2312");


$result = mysql_query("select * from ecs_order_info ");

echo "<table border='1' with='100%'>
<tr>
<th>客户名称</th>
<th>购买手机 </th>
<th>收货地址</th>
<th>购买数量 </th>
<th>购买时间</th>
<th>状态</th>
</tr>";

while ($row=mysql_fetch_array($result))
{

echo "<tr>";
echo "<td>" . $row["c**ignee"] . "</td>";

$rs = mysql_query("select top 1 * from ecs_order_goods,ecs_order_infowhere ecs_order_goods.order_id = ecs_order_info.order_id");

$rew = mysql_fetch_array($rs);
echo $rew;

echo "<td>" . $rew['goods_name'] .$row['order_id']. "</td>";
echo "<td>" . $row['address'] . "</td>";
echo "<td>" . $row['order_sn'] . "</td>";
echo "<td>" . $row['add_time'] . "</td>";
echo "<td>" . "OK" . "</td>";
echo "</tr>";


}

echo "</table>";
mysql_close($con);
?>



我的程序代码是这样的。但老是读不出来定单里的商品名称。

那位高手指示下。

回答:
返回的信息是

未命名.jpg