테스트 사이트 - 개발 중인 베타 버전입니다

초보 xml curl 공부 중인데 이거 대체 어떻게 적용하는건가요 채택완료

바람잡이소닉 9년 전 조회 4,606

http://bahndal.egloos.com/495377">http://bahndal.egloos.com/495377 

 

반달가면님 글인데 이걸 도무지 적용하기가 힘드내요 

 

 

댓글을 작성하려면 로그인이 필요합니다.

답변 1개

채택된 답변
+20 포인트

</p><p>$url = "<a href="<a href="http://freegeoip.net/xml/".$_GET['ip'" target="_blank" rel="noopener noreferrer">http://freegeoip.net/xml/".$_GET['ip'</a>"><a href="http://freegeoip.net/xml/" target="_blank" rel="noopener noreferrer">http://freegeoip.net/xml/</a>".$_GET['ip'</a>];
$ch = curl_init();
curl_setopt($ch, CURLOPT_AUTOREFERER, TRUE);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
$content = curl_exec($ch);
curl_close($ch);
$result = simplexml_load_string($content);
echo "<pre>";
print_r($result);</p><p>echo $result->RegionName;</p><p>

http://jjiniyam.cafe24.com/aa.php?ip=173.194.77.104">http://jjiniyam.cafe24.com/aa.php?ip=173.194.77.104 

로그인 후 평가할 수 있습니다

댓글을 작성하려면 로그인이 필요합니다.

답변을 작성하려면 로그인이 필요합니다.

로그인