Do sprawdzenia czy działa:
RewriteCond %{HTTP:Accept-Language} (aa|sq)$ [NC]
RewriteRule .* – [F,L]
źródło: http://freetools.webmasterworld.com/tools/htaccess-block-language/
ewentualnie
RewriteCond %{HTTP:Accept-Language} ^.*(en-gb|c|de|pt-br|ru-ru|de-de|it-it|sv-se|en-ca|fr-fr|ko-fr).*$ [NC]
RewriteRule ^(.*)$ – [F,L]
źródło: http://www.askapache.com/htaccess/modrewrite-tips-tricks.html
oznaczenia literowe krajów (alpha-2 code), tabela
https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements
—————————————-
i wątki takie:
#http://freetools.webmasterworld.com/tools/htaccess-block-language/
GeoIPEnable On
# Put countries to deny here
SetEnvIf GEOIP_COUNTRY_CODE PL DenyCountry
Deny from env=DenyCountry
Allow from all
# https://briansnelson.com/How_to_block_or_allow_countries_using_GeoIP_and_.htaccess
RewriteCond %{HTTP:Accept-Language} ^.*(en-gb|c|de|pt-br|ru-ru|de-de|it-it|sv-se|en-ca|fr-fr|ko-fr).*$ [NC]
RewriteRule ^(.*)$ – [F,L]
RewriteCond %{ENV:GEOIP_COUNTRY_CODE} ^(PL)$
RewriteRule ^(.*)$ – [F,L]
GEOIP COUNTRY CODE
To use this rules you need first download and install MaxMind, GeoIP software from MaxMind.com
# If is not enabled in apache config
#GeoIPEnable On
#GeoIPDBFile /usr/local/share/GeoIP/GeoIP.dat
##SetEnvIf GEOIP_COUNTRY_CODE CN BlockCountry
##SetEnvIf GEOIP_COUNTRY_CODE RU BlockCountry
##SetEnvIf GEOIP_COUNTRY_CODE NL BlockCountry
##Deny from env=BlockCountry
(http://www.vdsz.nl/category/topics-tags-internet/block-country)
