title: Apache mod_geoip - What will $_SERVER['GEOIP_COUNTRY_CODE'] / $_SERVER['GEOIP_CONTINENT_CODE'] equal if country / continent is unknown?
body: <p>We use apaches mod_geoip AND php's geoip.so modules to detect the country / continent a user is visiting from.</p>
  
  <p>Initially we just used PHP's, but a few months ago we began using geoip data within our apache configuration so now we use both.</p>
  
  <p>This is redundant.</p>
  
  <p>We are looking at disabling php's geoip.so since we already have the country / continent exposed in $_SERVER['GEOIP_COUNTRY_CODE'] / $_SERVER['GEOIP_CONTINENT_CODE'].</p>
  
  <p>Before we do this, we need to know what these 2 will equal IF geoip is unable to detect the location of the user.</p>
  
  <p>Previously, on the php end we used something along the lines of:</p>
  
  <pre><code>function geoiplookup($ip){
      if($return=@geoip_country_code_by_name($ip))
          return $return;
      return false;
  }
  </code></pre>
  
  <p>So if geoip_country_code_by_name was unable to retrieve the country code, and thus returned false, we set the script-stored country code to (bool)false.</p>
  
  <p>So,</p>
  
  <p>When using apache mod_geoip what does geoip set these 2 variables to if it is unable to retrieve the country code?</p>
  
  <p>Thanks.</p>