This blog uses Custom Content by Country (by iControlWP) to localize content. However, my tests with geopeeker.com were disappointing. The result was always U. S. related instead of the countries the servers were actually situated in. It turned out that it’s not a matter of the plugin itself (it’s fantastic!), but the data on IPs and countries is weak. The good thing is that I could increase accuracy by replacing the IP data with those from ip2location. Here is how I achieved it!
Go to your database administration tool (I use phpMyAdmin). There, select the table ip2nation, go to operations and truncate the table like shown below (please excuse that my hoster provides a German interface). Check whether you really selected the correct options!
Now download theย IP data which I already modified to suit our needs. Import the content of the CSV file to the still existing table ip2nation. This is simple, but see a screenshot below.
This should improve accuracy of Custom Content by Countries. Try again with geopeeker.com and be happy ๐
March 8, 2016 at 12:18 pm
Hi Jan,
I’m the author of the Content by Content country… I’m curious, could you possible supply us with the SQL import files in the same format. I’d be happy to use a better DB, but I’d need the data prepared in the correct format.
Is this possible? Please feel free to email me directly to chat about it!
Thanks!
Paul.
July 2, 2016 at 11:14 pm
This worked perfectly, thanks for putting this together ๐
July 6, 2016 at 7:43 am
I’m glad that I could help ๐
March 17, 2019 at 10:17 pm
Jan, this is an interesting article, and I want to follow the steps you’ve provided … however, this article is now 3 years old so I want to use the up to date version of the ip2location database.
Can you please describe the steps needed to prepare the ip2location data for importing into the ip2nations table?