jsobell
Forum Replies Created
-
Also, auto-download of database fails:
if ((isset ($result->errors)) || (! (is_in_array ('200', $result ['response'])))) die('ERROR');should be
if ((isset ($result->errors)) || (! (IP2LocationCountryBlocker::is_in_array ('200', $result ['response'])))) die('ERROR');And, it appears the DB1LITEBIN codes don’t work, only DB1LITE (which is CSV).
It appears
class IP2LocationCountryBlocker { var $countries = array(should be
class IP2LocationCountryBlocker { static $countries = array(and
517: foreach(IP2LocationCountryBlocker::countries as $countryCode => $countryName) {should be
517: foreach(IP2LocationCountryBlocker::$countries as $countryCode => $countryName) {Come on guys, please test the code before you make it live!
Forum: Plugins
In reply to: [IP2Location Country Blocker] Stop redirectPerhaps you should look at implementing this in the current version so we don’t have to reapply the fix every time we upgrade?
This isn’t a fix specific to us, as it’s going to be incorrect on every site with a theme or plugin that adds to headers.Cheers,
JasonForum: Plugins
In reply to: [IP2Location Country Blocker] Stop redirectRedirects fail on my installations because the check is performed after some header information has been sent.
I fixed it by changing index.php:add_action('wp_head', array('IP2LocationCountryBlocker', 'check'), 1);to
add_action('send_headers', array('IP2LocationCountryBlocker', 'check'), 1);Cheers,
Jason