Home >Backend Development >PHP Tutorial >PHP mobile phone number ownership query

PHP mobile phone number ownership query

PHP中文网
PHP中文网Original
2016-07-29 09:01:281824browse

PHP obtains the location of the mobile phone number
User Leaps/httpClient
can be directly replaced by file_get_contents
This API interface has been running stably since the SAE platform was launched in 2011. It has added support for segment 17. All collections are welcome and the limit is 10 concurrency

function getMobileInfo($mobile)
    {
        $http = new HttpClient ();
        $response = $http->get ( 'http://appyun.sinaapp.com/index.php?app=mobile&controller=index&action=api&outfmt=json&mobile='.$mobile );
        if ($response->getHttpCode () == '200') {
            $result = json_decode($response->getBody(),true);
            return $result;
        }
        return false;
}


Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn