|
In your .htaccess put the following. Add more SetEnvIfNoCase lines for each referer domain you want to forbid.
SetEnvIfNoCase Referer loan-here\.com fuckrefspam
SetEnvIfNoCase Referer debt-consolidation-reviews\.com fuckrefspam
SetEnvIfNoCase Referer 24x7-debt-consolidation\.com fuckrefspam
Order Allow,Deny
Allow from all
Deny from env=fuckrefspam
You can also use this method to block certain bots, offline browsers etc. eg: combine the two.
BrowserMatchNoCase ^WebReaper fuckthemall
BrowserMatchNoCase ^WebSauger fuckthemall
BrowserMatchNoCase "^Mister PiX" fuckthemall
BrowserMatchNoCase "^Offline Explorer" fuckthemall
BrowserMatchNoCase "^Download Ninja" fuckthemall
SetEnvIfNoCase Referer loan-here\.com fuckthemall
SetEnvIfNoCase Referer debt-consolidation-reviews\.com fuckthemall
SetEnvIfNoCase Referer 24x7-debt-consolidation\.com fuckthemall
Order Allow,Deny
Allow from all
Deny from env=fuckthemall
I use this method with great success. My bot list is very large and so I put this right into the apache config as opposed to the .htaccess which has to be read with each access.
|