<?php
//查询支付订单情况,引入方法;
require('function.php');
$pararm = array(
'spid' => '13266666666',
'merch_listid' => '201801073177958673'
);
ksort($pararm);
$par = http_build_query($pararm);
$sign = md5($par . '&key=12345');
$pararm['sign'] = $sign;
$par2 = http_build_query($pararm);
//GET请求;
$url = 'http://xxx.cgi?'. $par2 ;
$data1 = curl_get($url);
$org_data = xmlToArray($data1);
echo '<pre>';
var_dump($org_data);