I'm using the following code to block referrer spam on a site which is receiving a huge volume of spam traffic.
I'm told that it is more efficient in terms of server load to use httpd.conf, but I'm largely unfamiliar with this type of operation and haven't found much in the way of tutorials specific to the situation. Could anyone help with tutorials or resources showing similar methods of blocking referring domains?
RewriteEngine on
# Options +FollowSymlinks
RewriteCond %{HTTP_REFERER} spammer-one\.com [NC,OR]
RewriteCond %{HTTP_REFERER} spammer-two\.com
RewriteCond %{HTTP_REFERER} spammer-three\.com
RewriteRule .* - [F]
In addition is it worth investing the time in blocking via httpd.conf, will it significantly reduce server load compared to the htaccess code above?