Reputation: 325
Which detect location most accurate.
Upvotes: 4
Views: 953
Reputation: 2202
The Geo IP PECL package and Net_GeoIP PEAR package both provide an interface to the maxmind location database (that been mentioned in other answers) for PHP.
Upvotes: 0
Reputation: 52063
I've used IP2Location before and it works great. The free version will only return the country but the pay versions are very accurate and will return alot more information. They have API's for a lot of common languages.
Upvotes: 0
Reputation: 591
http://www.maxmind.com/ 's free API will get you to country level, and city for some IPs, if you pay them you can get some more detail, this information is a good default, but not 100% accurate. It's the best I've found.
Upvotes: 3