title: Htaccess To Block wp-comments-post.php Spam
body: <p>I am trying to block spam bots from submitting comments to my customized Wordpress blog. I want to do this via .htaccess but something seems to be wrong with my code because many spam bots are still getting through. Here's my htaccess code. The trick is that my Wordpress installation is not located at the domain root but in /wordpress/</p>
  
  <pre><code>RewriteEngine On
  RewriteCond %{REQUEST_METHOD} POST
  RewriteCond %{REQUEST_URI} /wordpress/wp-comments-post.php
  RewriteCond %{HTTP_REFERER} !.*mydomain.org.* [OR]
  RewriteCond %{HTTP_USER_AGENT} ^$
  RewriteRule (.*) http://%{REMOTE_ADDR}/$ [R=301,L]
  </code></pre>
  
  <p>Thanks! :)</p>