Closed emresaracoglu closed 6 years ago
I solved this method:
$externalContent = file_get_contents('http://checkip.dyndns.com/');
preg_match('/Current IP Address: \[?([:.0-9a-fA-F]+)\]?/', $externalContent, $m);
$externalIp = $m[1];
But what is the real solution to this?
It looks like you end up setting $ip
to 192.168.1.1 which is a reserved IP and isn't expected to be included in any of the GeoIP2 databases. You probably want to look through that conditional to figure out where the IP is coming from. This isn't related to the API itself though.
externalIp @emresaracoglu where should be place this code in Reader.php file ?
thanks
Hello,
I get this error because of my IP address. Access from different IP addresses but I get this error with my IP address.
what could be the reason?