基于php的违章接口调用代码实例
代码描述:基于php的违章接口调用代码实例
代码平台:聚合数据
<!--?php
// +----------------------------------------------------------------------
// | JuhePHP [ NO ZUO NO DIE ]
// +----------------------------------------------------------------------
// | Copyright (c) 2010-2015 All rights reserved.
// +----------------------------------------------------------------------
// | Author: Juhedata <info@-->
// +----------------------------------------------------------------------
//----------------------------------
// 违章直连通道调用示例代码- 聚合数据
// 在线接口文档:s/126
//----------------------------------
header('Content-type:text/html;charset=utf-8');
//配置您申请的appkey
$appkey = "*********************";
//************************
$url = "http://v./wzcxy/citys";
$params = array(
"key" => $appkey,//应用APPKEY
);
$paramstring = http_build_query($params);
$content = juhecurl($url,$paramstring);
$result = json_decode($content,true);
if($result){
if($result['error_code']=='0'){
print_r($result);
}else{
echo $result['error_code'].":".$result['reason'];
}
}else{
echo "请求失败";
}
//**************************************************
//************************
$url = "http://v./wzcxy/query";
$params = array(
"cityid" => "",//需要查询的城市ID
"carno" => "",//车牌号,需要UTF-8 UrlEncode
"en
基于php的违章接口调用代码实例 来自淘豆网m.daumloan.com转载请标明出处.