How do I enable GEOIP function for vhosts from httpd.conf?

You should configure your GeoIP database from LSWS web console, make sure to load the DB in binary format, not the one in CSV format.

Then you need to turn on GeoIP with the directive
GeoIPEnable On

in .htaccess or httpd.conf

Check the output of the phpinfo() page, the SERVER["GEOIP_...."] variables should be populated now.

  • Web Console, GeoIP
  • 1 Users Found This Useful
Was this answer helpful?

Related Articles

Replace SetEnvIf with RewriteRule to block bad clients

Situation: We use "SetEnvIf" in Apache to deny access to our site based on the user-agent, this...