PHP Obtenga la dirección IP
$clientIPAddress=$_SERVER['REMOTE_ADDR'];
Grepper
$clientIPAddress=$_SERVER['REMOTE_ADDR'];
$ip = $_SERVER['REMOTE_ADDR'];
$details = json_decode(file_get_contents("http://ipinfo.io/{$ip}/json"));
echo $details->city; // -> "Mountain View"