The form below generates a .htaccess file along with a .htpasswd file
that can be used to password protect a directory on your website. Using these files,
whenever someone visits a protected folder, a login box will pop up.
If the user submits an incorrect username/password combination, they will be denied
access to the folder.
I find this method to be particularly useful when I want to protect a personal folder that
contains images or other media. Rather than write a login form and form validation script,
I just upload these two files, and I'm done.
Please note that .htaccess is designed for the Apache Web Server. A how-to article concerning
password protection using .htaccess files can be found here.