PHPMac.com has posted a quick tutorial on how to "ban an IP" from your site.
In fact, it is only a seven-line code inserted at the top of your page!
Blocking certain IP addresses from your site is actually much easier than you might think.
The code basically just looks in an array of IP values and checks to see if the remote user's matches any of them. If it does, it echos out an error and stops the page execution. Obviously, this is just a basic example, and could be enhanced with a databse table that would be easier to manage than just the static array.