CURL과 관련하여 한 가지 문제가 있습니다. 나는 배열의 컬 응답을 얻을 수있는 방법이 .. 그래서 http://whatismyipaddress.com배열에서 CURL을받는 방법
에 CURL 요청을 보낼 시도하고있다? 지금은 HTML 페이지를 표시하지만 응답을 배열로 원하기 때문입니다.
여기내 코드는 ...
$ipAdd = '121.101.152.170';
$ch = curl_init("http://whatismyipaddress.com/ip/".$ipAdd);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION ,1);
curl_setopt($ch, CURLOPT_HEADER,0);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
$output = curl_exec($ch);
curl_close($ch);
echo $output;
그래서 ... 현재 내가 세부 HTML 페이지를 얻고 있지만, 내가 밖으로 배열 또는 XML로두고 싶다.
? 현재 "\ n"을 (를) 사용하면 도움이 될 수 있습니다. –
사전 허락을받지 않는 한, Shrapnel 대령이 지적한 바와 같이, 이것은 WhatIsMyIPAddress.com [이용 약관] (http://whatismyipaddress.com/terms-of-use)에 위배됩니다. –