Lines Matching refs:ip
5 This script uses the local copy of the ip-to-country.com
84 function i2c_search_in_index($ip)
91 __DIR__ . "/../backend/ip-to-country.idx",
103 $ip_chunk = (int) ($ip / $granularity);
126 // $ip should be an IP number and not an IP address
127 function i2c_search_in_db($ip, $idx)
135 $_SERVER['DOCUMENT_ROOT'] . "/backend/ip-to-country.db",
149 while (!feof($ipdb) && !($range_start <= $ip && $range_end >= $ip)) {
191 $ip = false;
195 $ip = $_SERVER["HTTP_CLIENT_IP"];
206 if ($ip) { array_unshift($ips, $ip); $ip = false; }
213 $ip = $ips[$i];
220 return $ip ?: $_SERVER['REMOTE_ADDR'];