请求这个url打开输出自己的ip, 用PHP提交后, IP为 101.32.22.109
↓↓↓
$url = 'https://quan.xianguomall.com/gaode2.php';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_HTTPHEADER, array('CLIENT-IP: 101.32.22.109','X-FORWARDED-FOR: 101.32.22.109'));
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_TIMEOUT, 30);
// 模拟来源
curl_setopt($ch, CURLOPT_REFERER, '');
$response = curl_exec($ch);
if($error=curl_error($ch)){
die($error);
}
curl_close($ch);
echo $response;