HOME BUY ONLINE DEVELOPERS PARTNERS SUPPORT ABOUT US CONTACT US
products
DB1 IP2Location™ IP-
Country
DB2 IP2Location™ IP-
Country-ISP
DB3 IP2Location™ IP-
Country-Region-City
DB4 IP2Location™ IP-
Country-Region-City-ISP
DB5 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude
DB6 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-ISP
DB7 IP2Location™ IP-
Country-Region-City-
ISP-Domain
DB8 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-ISP-
Domain
DB9 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
ZIPCode
DB10 IP2Location ™ IP-
Country-Region-City-
Latitude-Longitude-
ZIPCode-ISP-
Domain
DB11 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
ZIPCode-Timezone
DB12 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
ZIPCode-TimeZone
-ISP-Domain
DB13 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
Timezone-Netspeed
DB14 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
ZIPCode-Timezone-
ISP-Domain-Netspeed
DB15 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
ZIPCode-Timezone-
Areacode
DB16 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
ZIPCode-Timezone-
ISP-Domain-Netspeed-
Areacode
DB17 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
Timezone-Netspeed-
Weather
DB18 IP2Location™ IP-
Country-Region-City-
Latitude-Longitude-
ZIPCode-Timezone-
ISP-Domain-Netspeed-
Areacode-Weather
software products
DNx IP2Location™ .NET Component
JVx IP2Location™ Java Component
AXx IP2Location™ ActiveX/COM DLL
ISx IP2Location™ ISAPI Filter
WS1 IP2Location™ IP-Country Web Service
PX1 IP2Proxy™ IP-
Country
BOx BrowserObject™ Browser Detection
XML SOAP XML Web Services
CPS Custom Programming Services
free resources
IP2Location™ Application (Free)
IP2Location™ Online Demo (Free)
IP2Location™ Email Header Tracer (Free)
IP2Location™ IPV6-COUNTRY Free Edition
IP2Location™ API (Free)
IP2Location™ Articles & Tutorial (Free)
IP2Location™ Downloader Script (Free)
IP2Phrase™ Geo-Personalized Phrase (Free)
IP2Map™ Visitors Tracking by Map (Free)
World Country Information (Free)
ISO 3166 Country Code List (Free)
Flags of the World (Free)
 

Geo::IP2Location Perl Module

This module is a pure Perl API to support all IP2Location™ database products. It has been optimized for speed and memory utilization. Developers can use the API to qeury all IP2Location™ binary databases for applications written in Perl.
 
  Download - Perl Module
Geo::IP2Location [ Version 3.00 ]
 
  Download - Sample .BIN Files
IP2Location™ DB1 Sample .BIN File
IP2Location™ DB2 Sample .BIN File
IP2Location™ DB3 Sample .BIN File
IP2Location™ DB4 Sample .BIN File
IP2Location™ DB5 Sample .BIN File
IP2Location™ DB6 Sample .BIN File
IP2Location™ DB7 Sample .BIN File
IP2Location™ DB8 Sample .BIN File
IP2Location™ DB9 Sample .BIN File
IP2Location™ DB10 Sample .BIN File
IP2Location™ DB11 Sample .BIN File
IP2Location™ DB12 Sample .BIN File
IP2Location™ DB13 Sample .BIN File
IP2Location™ DB14 Sample .BIN File
IP2Location™ DB15 Sample .BIN File
IP2Location™ DB16 Sample .BIN File
IP2Location™ DB17 Sample .BIN File
IP2Location™ DB18 Sample .BIN File
 
Note: The demo version of Binary (.BIN) data file consists of IP address range from 0.0.0.0 to 99.255.255.255. The complete Binary (.BIN) data file is available for all paid subscribers at no extra cost. Please contact our sales department for the download information.
 
  Complete .BIN Files (Subscription Required)
IP2Location™ DB1 Full .BIN File
IP2Location™ DB2 Full .BIN File
IP2Location™ DB3 Full .BIN File
IP2Location™ DB4 Full .BIN File
IP2Location™ DB5 Full .BIN File
IP2Location™ DB6 Full .BIN File
IP2Location™ DB7 Full .BIN File
IP2Location™ DB8 Full .BIN File
IP2Location™ DB9 Full .BIN File
IP2Location™ DB10 Full .BIN File
IP2Location™ DB11 Full .BIN File
IP2Location™ DB12 Full .BIN File
IP2Location™ DB13 Full .BIN File
IP2Location™ DB14 Full .BIN File
IP2Location™ DB15 Full .BIN File
IP2Location™ DB16 Full .BIN File
IP2Location™ DB17 Full .BIN File
IP2Location™ DB18 Full .BIN File
 
  Installation
 
 
 
 
Please download the archive and sample databases into a temporary directory.
 
 
 
Decompress the archive
gunzip Geo-IP2Location-x.xx.tar.gz
tar -xf Geo-IP2Location-x.xx.tar.gz
 
 
 
 
Install Geo::IP2Location module
perl Makefile.PL
make
make test
make install
 
 
 
Decompress the sample databases
unzip samples-xxx.zip
 
  Public Methods
open(filename) Open IP2Location binary database from a local path.
get_country_short(ip_address) Returns a short country name from ip address.
get_country_long(ip_address) Returns a full country name from ip address.
get_region(ip_address) Returns a region name from ip address.
get_city(ip_address) Returns a city name from ip address.
get_latitude(ip_address) Returns city's latitude name from ip address.
get_longitude(ip_address) Returns city's longitude name from ip address.
get_isp(ip_address) Returns an ISP name from ip address.
get_zipcode(ip_address) Returns zip code from ip address.
get_timezone(ip_address) Returns time zone from ip address.
get_netspeed(ip_address) Returns connection type from ip address.
get_domain(ip_address) Returns a domain name from ip address.
get_iddcode(ip_address) Returns idd code from ip address.
get_areacode(ip_address) Returns area code from ip address.
get_weatherstationcode(ip_address) Returns weather station code from ip address.
get_weatherstationname(ip_address) Returns weather station name from ip address.
get_all(ip_address) Returns an array of country short name, country long name, region, city, latitude, longitude and domain name for an IP address.
 
  Sample Source Codes

use Geo::IP2Location;
$obj = Geo::IP2Location->open("IP-COUNTRY-REGION-CITY-LATITUDE-LONGITUDE-ISP-DOMAIN.BIN");

my $countryshort = $obj->get_country_short("20.11.187.239");
my $countrylong = $obj->get_country_long("20.11.187.239");
my $region = $obj->get_region("20.11.187.239");
my $city = $obj->get_city("20.11.187.239");
my $latitude = $obj->get_latitude("20.11.187.239");
my $longitude = $obj->get_longitude("20.11.187.239");
my $isp = $obj->get_isp("20.11.187.239");
my $domain = $obj->get_domain("20.11.187.239");
my $zipcode = $obj->get_zipcode("20.11.187.239");
my $timezone = $obj->get_timezone("20.11.187.239");
my $netspeed = $obj->get_netspeed("20.11.187.239");
my ($countryshort, $countrylong, $region, $city, $latitude, $longitude, $zipcode, $timezone, $isp, $domain, $netspeed) = $obj->get_all("20.11.187.239");
 

 
 
live product demo
 
IP2Location™ Internet
IP Address 2008
Report
 
live product demo
 
IP Address
 
 
Product Picker
 
Need help? Let me assist you to pick the right IP2Location products.

Click me now!
 
Our Customers
 
Our Customers
 
testimonials
"No doubt why security expert, Mike Schiffman, author of the Hacker’s Challenge book series recommended IP2Location™ in IP Geo project".
- S. Jones, California (United States)
"I am very satisfied with my purchase for my ip address log analysis project. Got my account immediately right after order approved. No hassle or delay time at all as I always thought. A must to meet project deadline".
- J. Wagner, New York (United States)
"Innovative products with low price tags compared with others million dollars geo-targeting products".
- Balakrishnan, Bangalore (India)
IP2Location Affiliate Program
 
Earn up to 20% on Sales from New Customer and
2-Year Return Commission
More Information
as seen in
 
msdn
 
eWeek
 
product overview
 
Take a closer look in this in-depth tour and learn more about IP2Location™ products:
IP2Location™ Product Overview
IP2Location™ Product Brochure
showcase
Web Sites Powered by IP2Location™
Geolocation IP Address by IP2Location Prevent Credit Card Fraud by Fraudlabs Zip Code Database Solution by ZIPCodeWorld.com Geographic City Database by GeoDataSource Browser Detection by BrowserObject