-
$ip = $_SERVER['REMOTE_ADDR']; // 아이피 주소받음 $details = json_decode(file_get_contents("http://ipinfo.io/"));// 받음받음 echo $details->country; // 어느나라니 echo $details->city; // 어느도시니