I've noticed from testing some of my landers with VPNs/proxies that the maxmind script works for large European cities, but smaller ones seem to return nothing and just get a blank on the lander.
Are there any available alternatives that are more accurate and will return at least a location close by?
The only alternatives I know of are:
http://www.ip2location.com/faqs/db3-...ry-region-city
Which has a pretty decent number of IPs in a lot of countries, don't know whether it's better than MaxMind, but claims 99% country accuracy and large IP database than competitors.
A high level solution would be Neustar - http://www.quova.com/why/target-advertising/
Digital Envoy is another but they are not cheap
If only one could harness the power of Google somehow, since they most likely have the most comprehensive database on the planet.
hey guys! decided to switch to a paid version instead of maxmind (free) and have recently purchased a database pack from ip2location and guys from the hosting company have placed it in .BIN format into a folder for me. How do I utilize it? The hosting company guy says I need an application for that sending me to this page here: http://www.ip2location.com/developers/php
My skills are just enough to modify some html and css but I never had to deal with any apps or PHP myself. Can anyone advise on what should I do now?
Any help is much appreciated!
@toneko
<?php
require_once('ip2location.class.php');
$ip = new ip2location;
$ip->open('./databases/IP-COUNTRY-SAMPLE.BIN');
$record = $ip->getAll($_SERVER["REMOTE_ADDR"] );
?>
$ip->open('./databases/IP-COUNTRY-SAMPLE.BIN');
require_once('ip2location.class.php');
Meet single women in <?php echo $record->city ?>
. But, hopefully this gets you going in the right direction. Perhaps someone that actually uses it can offer some better examples.Thanks a lot Aaron! I'm going to try that out.
ok guys, I created a /databases folder in the same directory where my index.php is and placed a database .BIN file into it. I have also uploaded the ip2location.class.php file into the same directory, then I copy- pasted this code [PHP]<?php
require_once('ip2location.class.php');
$ip = new ip2location;
$ip->open('./databases/IP-COUNTRY-SAMPLE.BIN');
$record = $ip->getAll($_SERVER["REMOTE_ADDR"] );
?>[/PHP] into <body></body> and changed IP-COUNTRY-SAMPLE.BIN to the actual DB filename which is IP-COUNTRY-REGION-CITY.BIN
I created the databases folder in the same directory because previously when I changed the path it unfortunately couldn't find it on the server.
Anyways, doing all the above keeps giving me the following error:
Ok guys, it appears that I need a developer to utilize my recently purchased ip2location database. Tried a bit of php coding myself- never worked out for me.
The guys from the hosting company said the following: