WordPress.org

Plugin Directory

Test out the new Plugin Directory and let us know what you think.

IP2Location Tags

Displays visitor’s geolocation information and customize the page content for different countries.

Allows you to easily get the visitor's geolocation information based on IP address and customize the page content for different countries and regions.

Key Features

  • Displays visitor’s’ information such as
    • Country code
    • Country name
    • Country flag
    • Region name
    • City name
    • Latitude and longitude
    • ZIP code
    • ISP
    • Domain name
    • Time zone
    • Net speed
    • IDD code
    • Area code
    • Weather station code & name
    • MNC, MCC, mobile carrier name
    • Elevation
    • Usage type
  • Customize the page content based on country or region
  • Supports IPv4 and IPv6

This plugin supports both IP2Location BIN data and web service for geolocation queries. If you are using the BIN data, you can update the BIN data every month by using the wizard on the settings page for the accurate result. Alternatively, you can also manually download and update the BIN data file using the below links:

BIN file download: IP2Location Commercial database | IP2Location LITE database (free edition)

If you are using the web service, please visit IP2Location Web Service for details.

Get visitor's location information with Variable Tag

Usage example

Display visitor's IP address, country name, region name and city name. Your IP is {ip:ipAddress} You are in {ip:countryName}, {ip:regionName}, {ip:cityName}

Customize the post content with IP2Location Tag

Syntax to show content for specific country [ip:XX[,XX]..[,XX]]Your content here.[/ip] Note: XX is a two-character ISO-3166 country code.

Example To show the content for United States or Canada visitors only. [ip:US,CA]Only visitors from United States or Canada can view this line.[/ip]

Syntax to show content for specific country and region [ip:XX:YY[,XX:YY]..[,XX:YY]]Your content here.[/ip] Note: XX is a two-character ISO-3166 country code and YY is a ISO-3166-2 sub-division code.

Example To show the content for California or New York visitors only. [ip:US:CA,US:NY]Only visitors from California or New York can view this line.[/ip]

Syntax to hide the content from specific country [ip:*,-XX[,-XX]..[,-XX]]Your content here.[/ip] Note: XX is a two-character ISO-3166 country code.

Example All visitors will be able to see the line except visitors from Vietnam. [ip:*,-VN]All visitors will be able to see this line except visitors from Vietnam.[/ip]

Syntax to hide the content from specific country and region [ip:*,-XX:YY[,-XX:YY]..[,-XX:YY]]Your content here.[/ip] Note: XX is a two-character ISO-3166 country code and YY is a ISO-3166-2 sub-division code.

Example All visitors will be able to see the line except visitors from California. [ip:*,-US:CA]All visitors will be able to see this line except visitors from California.[/ip]

More Information

Please visit us at http://www.ip2location.com

Requires: 2.0 or higher
Compatible up to: 4.7.1
Last Updated: 3 weeks ago
Active Installs: 200+

Ratings

3.7 out of 5 stars

Support

0 of 1 support threads in the last two months have been marked resolved.

Got something to say? Need help?

Compatibility

+
=
Not enough data

0 people say it works.
0 people say it's broken.

100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
0,1,0
0,1,0