PHP Express Query interface
function Kuaidi100_scan ($getcom, $invoice _sn) { switch ($getcom) { case "EMS": $ postcom = ' EMS '; break; case "China Post": $postcom = ' EMS '; break; case "Shentong Express": $postcom = ' Shentong '; Break; case "Yuantong Express": $postcom = ' Yuantong '; bReak; case "Shun Fung Express": $postcom = ' Shunfeng '; break; case "Daily Express": $postcom = ' Tiantian '; break; case "Yun da Express": $postcom = ' Yunda '; break; case "Zhong Tong Express": $postcom = ' Zhongtong '; break; Case "Dragon State Logistics":  &NBsp; $postcom = ' Longbanwuliu '; break; Case "Home emergency delivery": $postcom = ' Zhaijisong '; break; case "All One Express": $postcom = ' Quanyikuaidi '; break; case "Hui Tong Express": $postcom = ' Huitongkuaidi '; break; case "Civil Aviation Express": $postcom = ' Minghangkuaidi '; break; case "Asia Wind Express": $postcom = ' Yafengsudi '; break; case "Express Express": $postcom = ' Kuaijiesudi '; break; case "Huayu Logistics": $postcom = ' Tiandihuayu '; break; case " Chinese Railway Express ": $postcom = ' Zhongtiewuliu '; &nBsp; break; case "FedEx ": $postcom = ' FedEx '; break; Case "Ups": $postcom = ' ups '; break; case "DHL": $postcom = ' DHL '; break; default: $postcom = '; } if (Empty ($postcom)) { return false; } $curr _time = time (); $url = ' http:/ /m.kuaidi100.com/query?type= '. $postcom. ' &id=1&postid= '. $invoice _sn. ' &temp= '. $curr _time; $res = file_get_contents ($url); $res = JSON _decode ($res, True); if ($res [' status '] = =) { return $res [' data ']; } return false;} Kuaidi100_scan ("Zhong Tong Express", "375590702050");
The above on the introduction of the PHP Express query interface, including the aspects of the content, I hope that the PHP tutorial interested in a friend helpful.