How to get visitor IP details using PHP and MySQL

Today we are going to learn how to get visitor IP details using PHP and MySql. For this tutorial i have used PHP classes to get IP details from Databases. It is useful to handle your visitors like IP based banned, For analytics, For translation and much more ….

Features:

  • Convert IP into  numerical Value
  • IP registry
  • IP country RIR (Regional Internet Registry) representation
  • IP Country
  • IP range

It is simple to use.

Database table structure:

IP dump have given in this script package

phpip2country.class.php:

index.php:

Reference : http://code.google.com/p/php-ip-2-country/

thanks…
Demo and Download

 

Note:

Please don’t forget to share and subscribe to latest updates of the blog .