Cheat Sheets
mod_rewrite (V2)
mod_rewrite (V1)
Articles
HTTP Status Codes for Beginners
All valid HTTP 1.1 Status Codes simply explained.
Blog and Lab
Block Referrer Spam (Updated)
Referrer spam is becoming increasingly common. At best, it will only render your log files useless. At worst, it can cause your site to be dropped by search engines and your running costs to skyrocket. Here's how to block spurious referrers.
Click here to read this post »
14 September 2005 | 41 comments | howto, webdev, server, spam, referrer, wordpress, htaccess, admin, apache
Ignore Directories in mod_rewrite
A quick piece of code for you. If you are using mod_rewrite and creating RewriteRules for a website that emulate a directory structure, you might happen across the same problem I've had. If you have actual, real folders on the site as well, you don't want requests for items in those folders to be rewritten. You need a way to prevent the RewriteRule(s) matching the real folders. The easiest way to do this is (I think) by adding a RewriteRule for each of the real folders, like the below. This rule will match any request to those folders and prevent it being rewritten later in the set of rules.
RewriteRule ^folder_name/.*$ - [PT]
Password Protect a Directory with .htaccess
A tutorial explaining how to retrict access to a directory on a web server using .htaccess.
Click here to read this post »
15 March 2005 | 84 comments | howto, webdev, security, programming, php, password, protect, sysadmin, htaccess, website, apache, directory, generator
