Password protecting one area of a site

Hello all!

I run a business that videos weddings. Our website is currently hosted on Dreamhost and I was wondering if there was a way to have certain sites password protected, while leaving all others normal…

For example, we’re wanting to offer a deal where, for a fee, we will host a bride’s wedding video on line so that they can show it off to friends and family. In order to do this, we need to create a directory for the bride, but have it password protected so that she could just send the login info to anyone who she wants to see it. So, let’s say it’s “”. I’d like a bride to be able to enter “”, a username/password prompt come up, they type the info i give them, then have access to their personal site.


Thanks for any input!


You can easily set that up with .htaccess.

Simon’s website
Save $100 on 1-year plans with promo code [color=#CC0000]SCJESSEY100[/color] (details)

That’s very easy to set up. Just put the video in its own directory, then use the Control Panel–>Goodies–>WebDAV / htaccess protection screen to set a user/pass combination for that directory, and you are good to go. You can set up as many directories as you want this way.


that is right. now i’m getting into htaccess. it is really helpful

Save [color=#CC0000]$97[/color] (max discount) on dreamhost plans by using promo code: [color=#CC0000]97CRAZY[/color].

Alright, that works great, but now I’m curious about another thing in a similar vein.

Now I’m curious how I’d go about having a “login” link on my home page that, when they client enters their own personal username/password they are redirected to their own part of the site. So rather than having to send each client a unique link to a password protected site, have a universal login link on the front page. Make sense?

Thanks for the help!


You’ll probably get a lot better luck with this question if you make a new thread (it really is a different subject altogether) :wink:

Short answer: That’s a job for some back-end server-side scripting - PHP or perl ought to work fine, and there are lots of code examples out there to get you started. You may even be able to find a script that pretty much does what you want “out of the box”