ts2000abc Posted October 22, 2009 Share Posted October 22, 2009 Does anyone know if there is some way (open/free API for example) for transferring users IP-address to GPS coordinates? I’m trying to make map software that shows users location… Link to comment https://forums.phpfreaks.com/topic/178611-ip-address-to-gps-coordinates/ Share on other sites More sharing options...
cbolson Posted October 22, 2009 Share Posted October 22, 2009 Take a look at geoip here: http://www.maxmind.com/ Chris Link to comment https://forums.phpfreaks.com/topic/178611-ip-address-to-gps-coordinates/#findComment-942021 Share on other sites More sharing options...
ts2000abc Posted October 22, 2009 Author Share Posted October 22, 2009 ok... can this be done with php geoip extension? (http://php.net/manual/en/book.geoip.php) then i wouldn't need to use any third party api's Link to comment https://forums.phpfreaks.com/topic/178611-ip-address-to-gps-coordinates/#findComment-942041 Share on other sites More sharing options...
cbolson Posted October 22, 2009 Share Posted October 22, 2009 If you check the php.net docs: http://www.php.net/manual/en/geoip.requirements.php you will see that this requires this : http://www.maxmind.com/app/c which is the same company as the url that I posted. It appears (haven't tried it myself) that this needs to be complied on your server. Chris Link to comment https://forums.phpfreaks.com/topic/178611-ip-address-to-gps-coordinates/#findComment-942049 Share on other sites More sharing options...
tail Posted October 22, 2009 Share Posted October 22, 2009 $ip = $SERVER["REMOTE_ADDR"]; $tags = get_meta_tags('http://www.geobytes.com/IpLocator.htm?GetLocation&template=php3.txt&IpAddress='.$ip.''); print $tags['city']; // city name More info: http://www.geobytes.com/IpLocator.htm Link to comment https://forums.phpfreaks.com/topic/178611-ip-address-to-gps-coordinates/#findComment-942208 Share on other sites More sharing options...
junejune Posted March 8, 2010 Share Posted March 8, 2010 You can check out the GeoLocation databases from http://www.IP2Location.com or you can use a free web service like the ones from http://www.FraudLabs.com to get the latitude and longitude. Link to comment https://forums.phpfreaks.com/topic/178611-ip-address-to-gps-coordinates/#findComment-1022883 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.