WordPress.org

Plugin Directory

iQ Block Country

Block visitors from countries you don't want on your website. Based on which country your visitor is from.

Why is the GeoLite database not downloaded anymore ?

The WordPress guys have contacted me that the license of the MaxMind GeoLite database and the WordPress license conflicted. So it was no longer allowed to include the GeoLite database or provide an automatic download or download button. Instead users should download the database themselves and upload them to the website.

WordPress could be held liable for any license issue. So that is why the auto download en update was removed from this plugin.

How come that I still see visitors from countries that I blocked in Statpress or other statistics software?

It’s true that you might see hits from countries that you have blocked in your statistics software. That is the way it works, certain plugins may be run before iQ Block Country is run so it may log visitors to pages.

This however does not mean this plugin does not work, it just means somebody tried to access a certain page or pages and that that fact is logged.

If you are worried this plugin does not work you could try to block your own country or your own ip address and afterwards visit your frontend website and see if it actually works. Also if you have access to the logfiles of the webserver that hosts your website you can see that these visitors are actually denied with a HTTP error 403.

This plugin does not work, I blocked a country and still see visitors!

Well, this plugin does in fact work but is limited to the data MaxMind provides. Also in your statistics software or logfiles you probably will see log entries from countries that you have blocked. See the "How come I still see visitors..." FAQ for that.

If you think you have a visitor from a country you have blocked lookup that specific IP address on the tools tab and see which country MaxMind thinks it is. If this is not the same country you may wish to block the country that MaxMind thinks it is.

Whoops I made a whoops and blocked my own country from visiting the backend. Now I cannot login... HELP!

I am afraid this can only be solved by editing your MySQL database,directly editing the rows in the wp_options table. You can use a tool like PHPMyAdmin for that.

If you don't know how to do this please ask your hosting provider if they can help, or ask me if I can help you out!

Why do you not make something that can override that it blocks my country from the backend.

Well, if you can use a manual override so can the people that want to 'visit' your backend.

This plugin is meant to keep people out. Perhaps you keep a key to your house somewhere hidden in your garden but this plugin does not have a key somewhere hidden... So if you locked yourself out you need to call a locksmith (or pick the lock yourself of course!)

How can I style the banned message?

You can style the message by using CSS in the textbox. You are also able to include images, so you could visualize that people are banned from your site.

You can also provide a link to another page explaining why they might be banned. Only culprit is that it cannot be a page on the same domain name as people would be banned from that page as well.

You can use for instance:

body { color: red; background-color: #ffffff; } h1 { font-family: Helvetica, Geneva, Arial, SunSans-Regular, sans-serif }

Go away!

you basicly can use everything as within a normal HTML page. Including images for instance.

Does this plugin also work with IPv6?

Since v1.0.7 this plugin supports IPv6. But as IPv6 is still scarce it may not work as well as IPv4. Some IPv6 blocks may not be in the right country in the MaxMind database.

There are no guarantees blocking IPv6 works but as far as I was able to test IPv6 blocking it works just fine.

Does this plugin work with caching?

In some circumstances: No

The plugin does it best to prevent caching of the "You are blocked" message. However most caching software can be forced to cache anyway. You may or may not be able to control the behavior of the caching method.

The plugin does it bests to avoid caching but under circumstances the message does get cached. Either change the behavior of your caching software or disable the plugin.

How can I select multiple countries at once?

You can press the CTRL key and select several countries.

Perhaps also a handy function is that you can type in a part of the name of the country!

How can I get a new version of the GeoIP database?

You can download the database(s) directly from MaxMind and upload them to your website.

  1. Download the IPv4 database from: http://geolite.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz
  2. Unzip the GeoIP database and upload it to your upload dir usually /wp-content/uploads/GeoIP.dat
  3. Download the IPv6 database if you have a website running on IPv6 from: http://geolite.maxmind.com/download/geoip/database/GeoIPv6.dat.gz
  4. Unzip the GeoIP database and upload it to your upload dir usually /wp-content/uploads/GeoIPv6.dat

Maxmind updates the GeoLite database every month.

I get "Cannot modify header information - headers already sent" errors

This is possible if another plugin or your template sends out header information before this plugin does. You can deactivate and reactivate this plugin, it will try to load as the first plugin upon activation.

If this does not help you out deselect "Send headers when user is blocked". This will no longer send headers but only display the block message. This however will mess up your website if you use caching software for your website.

What data get sends to you when I select "Allow tracking"?

If you select this option each hour the plugin checks if it has new data to send back to the central server.

This data consists of each IP address that has tried to login to your backend and how many attempts were made since the last check.

Goal of this feature is to check if we can create a user-driven database of rogue IP addresses that try to login to the backend. If this is viable in a future version this database can be used to block these rogue users despite the country they come from.

If storing or sharing an IP address is illegal in your country do not select this feature.

The laws in my country do not allow storing IP addresses as it is personal information.

You can select the option on the home tab "Do not log IP addresses" to stop iQ Block Country from logging IP addresses. This will however also break the statistics.

Requires: 3.5.2 or higher
Compatible up to: 4.1.5
Last Updated: 2015-3-13
Active Installs: 10,000+

Ratings

3.8 out of 5 stars

Support

8 of 10 support threads in the last two months have been resolved.

Got something to say? Need help?

Compatibility

+
=
Not enough data

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

67,3,2 50,2,1 100,1,1
50,2,1
100,3,3
100,1,1
100,1,1
0,3,0
0,1,0
100,1,1
0,1,0
100,2,2
0,1,0
0,2,0
50,4,2 100,1,1 67,3,2 100,1,1
67,3,2
100,1,1 25,4,1 100,1,1
100,2,2 100,1,1 100,1,1 100,1,1
100,2,2
0,1,0
0,1,0 100,1,1 100,1,1 100,1,1 100,1,1 100,1,1 100,1,1
100,1,1 100,1,1 100,1,1 100,1,1 100,1,1
100,1,1 100,1,1 100,2,2 100,2,2 0,1,0 100,1,1
100,1,1
100,1,1
100,2,2 100,1,1
100,1,1 100,1,1
100,2,2
100,1,1
100,1,1
50,2,1