传递参数

wsk/addorder?goods=[{"gsn":802006,"number":1},{"gsn":103761,"number":3}]

错误:

$goods = $_GET['goods'];
print_r(json_decode($goods,true));

正确:

$goods = $_GET['goods'];
json = iconv('GBK','utf-8',$goods);
//$json = stripslashes($json);
$json = htmlspecialchars_decode($json);
print_r(json_decode($json,true));
05-08 08:33