IP Address Geolocation From MySQL
Want to support HowtoForge? Become a subscriber!
IP Address Geolocation From MySQLIn this short tutorial I will use a local MySQL database to do IP addresses geolocation. First download the database from this page: http://blogama.org/node/58 And then go in your favorite MySQL interface and type: SELECT * FROM `ip_group_city` where `ip_start` <= 4881709 order by ip_start desc limit 1; IP addresses use this format (example IP A.B.C.D): ip = (A*256+B)*256+C For example, if you have an ip of 74.125.45.100 (Google): It would become in the database: ip = (74*256+125)*256+45 = 4881709
|



Recent comments
2 hours 28 min ago
7 hours 17 min ago
12 hours 6 min ago
14 hours 26 min ago
14 hours 43 min ago
14 hours 55 min ago
18 hours 56 min ago
19 hours 41 min ago
21 hours 54 min ago
1 day 5 hours ago