} else { $start = 0; $end = $count; $limit = 1000; } function geoipUpdateError($message) { Log::error($message); Common::sendHeader('HTTP/1.1 500 Internal Server Error', $replace = true, $responseCode = 500); exit; } // only display notes if on command line (where start will == 0 for that part of script) or on // first AJAX call by browser $displayNotes = $start == 0; // try getting the pecl location provider $provider = new Pecl(); if (!$provider->isAvailable()) { if ($displayNotes) { Log::info("[note] The GeoIP PECL extension is not installed."); } $provider = null; } else { $workingOrError = $provider->isWorking(); if ($workingOrError !== true) { if ($displayNotes) { Log::info("[note] The GeoIP PECL extension is broken: {$workingOrError}"); } if (Common::isPhpCliMode()) { Log::info("[note] Make sure your command line PHP is configured to use the PECL extension."); } $provider = null;