Welcome aboard! We are happy you are here and wish you good net-raft!
<!DOCTYPE html>
<html>
<body>
<?php
$ip = $_REQUEST['REMOTE_ADDR'];
$query = @unserialize(file_get_contents('http://ip-api.com/php/'.$ip));
if($query && $query['status'] == 'success') {
echo $query['region'].', '.$query['country'].', '.$query['city'];
}
?>
</body>
</html>
The most helpful PHP solutions
detect browser phpPHP Click to see more ... 4.6K 408