I get 6-10 sign ups from places like Nigeria and Ghana in Africa. I'm currently capturing IPs so is it possible to restrict a range of IPs from a specific country?
If I can retrict them does it make more sense to add this range to my .htaccess file or restrict them at the site level?
You can get the maxmind database:
http://www.maxmind.com/app/mod_geoip
and use this code:
GeoIPEnable On
GeoIPDBFile /path/to/GeoIP.dat
# Redirect multiple countries to a single page
RewriteEngine on
RewriteCond %{ENV:GEOIP_COUNTRY_CODE} ^(NI|GH)$
RewriteRule ^(.*)$ - [F]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With