Entered IP Address : 123.2.152.45 Entered Hostname : unresolveable Entered ASN Number : N-A Entered ASN Organization : N-A Entered Location Latitude : 51.2993°N Entered Location Longitude : 9.491°E Entered Google Map Links : Wide Angle and Close In Entered Postal Code : N-A Entered City Name : N-A Entered Region Name : N-A Entered Country Name : Germany Entered Country Code : DE Entered Country Capital : Berlin Entered Country Flag :See Large Flag - Show ALL Country Flags Entered Country Currency : Euro Entered Continent Code : EU Entered Continent Name : Europe Entered Time Zone : Europe/Berlin
First, it uses various HTTP variables to find the browser language, type, where you surfed from - i.e. what your IP address is (plus the referrer) - DNS is used to lookup the hostname from the later. Note that if you are using a web proxy (quite common in Corporate Environments), that IP address and hostname is what will be shown/used.
It then uses the Perl Module GeoIP2 and the MaxMind database to lookup the country and city information based on the IP address. Note that you can enter a domain name or IP address manually. BTW, there are more extensive databases that will provide more precise location data, but those cost dollars and this is meant just as quick-n-simple demo.
Javascript is used to determine all of the values from timezone on down.
BTW, the images of the flags came from the CIA Factbook web site and
here's a nifty map of the world.
Please do not Email me asking for a copy of the code or more pointers
on how to do this - use the resources mentioned above. Also, please do not
use automated scripts to access this page.