Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/256.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
php curl GET请求执行多次_Php_Curl - Fatal编程技术网

php curl GET请求执行多次

php curl GET请求执行多次,php,curl,Php,Curl,我正在使用curl GET请求。它在XAMPP上运行良好,当我将我的站点上传到云时,GET请求执行了不止一次。可能有什么问题。有人能推荐我吗。下面是我的curl-GET请求 $service_url= "http://xxxmeal.com/get_meals?lat=19.2332&lng=14.3422" $curl = curl_init ( $service_url ); curl_setopt ( $curl, CURLOPT_RETURNTRANSFE

我正在使用curl GET请求。它在XAMPP上运行良好,当我将我的站点上传到云时,GET请求执行了不止一次。可能有什么问题。有人能推荐我吗。下面是我的curl-GET请求

    $service_url= "http://xxxmeal.com/get_meals?lat=19.2332&lng=14.3422"
    $curl = curl_init ( $service_url );
    curl_setopt ( $curl, CURLOPT_RETURNTRANSFER, true );
    $curl_response = curl_exec ( $curl );
    curl_close ( $curl );

很抱歉,它不是原始地址,根据公司政策,我不能透露地址,但当我使用php编写上述代码时,它会多次访问url,在这种情况下,请启用详细日志记录并自行检查。否则我们只能猜测到底发生了什么,因此这个问题无法真正得到回答。kk,无论如何,谢谢你,我会努力的。