Any good free geoip scripts or db?

Ye' old general discussion board. Basically, for everything that isn't covered elsewhere. Come here to shoot the breeze, shoot your mouth off, or whatever suits your fancy.
This forum is not for asking programming related questions.

Moderator: General Moderators

Post Reply
GeXus
Forum Regular
Posts: 631
Joined: Sat Mar 11, 2006 8:59 am

Any good free geoip scripts or db?

Post by GeXus »

I'm looking for a free geo ip script that can get city and state data... Anyone have any recommendations?

Thanks!
jfanaian
Forum Newbie
Posts: 6
Joined: Fri Jun 02, 2006 2:57 pm

Post by jfanaian »

Never having tried this I have no solution that I know of. I did a bit of research though and came accross this PEAR class by MaxMind. You might want to take a look at it and see what it provides. It uses the MaxMind database to generate the geographical location of an IP address.
PEAR: http://pear.php.net/pepr/pepr-proposal-show.php?id=91
MaxMind: http://www.maxmind.com/app/php

If neither of these work, my other and simplest solution would be just to use one of the free query sites and just rip off the Geo data from there. Use of cURL can help this. When I have more time I'll be trying out the PEAR class and see how it works.

Hope this helps though :)

Good luck with your coding,
Jamal

P.S. Let me know how it works out as this is something I want to try out as well sometime :)
jfanaian
Forum Newbie
Posts: 6
Joined: Fri Jun 02, 2006 2:57 pm

Post by jfanaian »

I wrote an article on how to do it: http://www.phpfriendly.com/determining- ... ip-geoip-7
timvw
DevNet Master
Posts: 4897
Joined: Mon Jan 19, 2004 11:11 pm
Location: Leuven, Belgium

Post by timvw »

I wrote something similar a coupe of years ago:

http://timvw.madoka.be/programming/php/banner.txt
http://timvw.madoka.be/programming/php/ip2location.txt

I used to have an online demo page... But threw that away..
Post Reply