curl get请求
<?php
/**
* curl GET请求
*/
function curlGet($url){
$ch = curl_init($url);
curl_setopt_array($ch,[
CURLOPT_RETURNTRANSFER => true,
]);
$output = curl_exec($ch);
curl_close($ch);
return $output;
}
推荐文章: