本DEMO中的PHP快递运单号查询都是原创,代码简单,可直接使用。通常可应用在发货和退货等场景。提示:无快递查询次数限制。

第一种根据运单号类型和运单号判断:
第二种根据运单号直接查询:
支持的快递运单号类型有:

<?php 

        $codes = array(

            0=>array(

                "code"=>"ems",

                "name"=>"ems快递",

            ),

            1=>array(

                "code"=>"shentong",

                "name"=>"申通快递",

            ),

            2=>array(

                "code"=>"yuantong",

                "name"=>"圆通速递",

            ),

           3=>array(

                "code"=>"shunfeng",

                "name"=>"顺丰速运",

            ),

            4=>array(

                "code"=>"tiantian",

                "name"=>"天天快递",

            ),

            5=>array(

                "code"=>"yunda",

                "name"=>"韵达快递",

            ),

            6=>array(

                "code"=>"zhongtong",

                "name"=>"中通速递",

            ),

            7=>array(

                "code"=>"longbanwuliu",

                "name"=>"龙邦物流",

            ),

            8=>array(

                "code"=>"zhaijisong",

                "name"=>"宅急送",

            ),

            9=>array(

                "code"=>"quanyikuaidi",

                "name"=>"全一快递",

            ),

             10=>array(

                "code"=>"huitongkuaidi",

                "name"=>"汇通速递",

            ),

             11=>array(

                "code"=>"minghangkuaidi",

                "name"=>"民航快递",

            ),

             12=>array(

                "code"=>"yafengsudi",

                "name"=>"亚风速递",

            ),

             13=>array(

                "code"=>"kuaijiesudi",

                "name"=>"快捷速递",

            ),

            14=>array(

                "code"=>"tiandihuayu",

                "name"=>"天地华宇",

            ),

            15=>array(

                "code"=>"zhongtiekuaiyun",

                "name"=>"中铁快运",

            ),

            16=>array(

                "code"=>"deppon",

                "name"=>"德邦物流",

            ),

            17=>array(

                "code"=>"yousukuaidi",

                "name"=>"优速快递",

            ),

            18=>array(

                "code"=>"yeahyoung",

                "name"=>"越洋仓国际供应链",

            ),

        );

        ?>