How to connect to Aicha Express interface
1. First go to Aicha Express http://www.ickd.cn/api/reg.html to apply for KEY. It is very fast, and the application is completed in a few minutes. Much better than Express 100, and the service is much better.
2. Create a form, submit data, and the sending address is: $url ='http://api.ickd.cn/?com='.$typeCom.'&nu='.$typeNu.'&id='. $key.'&type=html&encode=utf8';
Just bring in the value of the expression and you can submit it.
The implementation code is:
example.html
[html]
快递公司:
快递单号:
说明:查询时需要发送两个参数:公司名(拼音或英文);快递单号
获取范例:
get.php
[php]
header('Content-type:text/html;charset=utf-8');
//echo '*****';
$typeCom = $_GET["expressid"];//Express company www.2cto.com
$typeNu = $_GET["expressno"]; //Express tracking number
$key='**********';//Tohttp://www.ickd .cn/api/reg.htmlApplication
$url ='http://api.ickd.cn/?com='.$typeCom.'&nu='.$typeNu.'&id='.$key.'&type=html&encode=utf8';
//echo $url;
$data = file_get_contents($url);
echo $data;
?>
Author: hljflp