Re: Newbie Question: Password protect a webpage

From: Elliott Back (elliott_at_cornell.edu)
Date: 10/24/04


Date: Sun, 24 Oct 2004 11:52:21 GMT

Paige Miller wrote:
> I'm trying to come up with a very low-security password protected
> web-page. I have found some short java code on the internet at
> http://www.dynamicdrive.com/dynamicindex9/password.htm that will do what
> I want, if only I could figure out one little thing.
>
> On the gateway page, you place a javascript which asks for the password,
> and then only if the proper password is provided do you allow access to
> the next page. Great. Exactly what I want.
>
> What I can't figure out is this: let's say the password protected page
> is named http://somewhere.com/abraham.html. How do I stop people from
> noticing that name, after the first time they correctly supply the
> password, from going directly to that page (bypassing the need to supply
> the password). If someone makes this page a Favorite, it appears they
> can go directly to this page, not what I want. How do I fix this?
>
> Thanks!
>

Try using .htaccess to do HTTP authentication:

http://www.calpoly.edu/~www/htaccess_setup.html

-- 
Thanks,
Elliott C. Bäck
---------------------------------
www.elliottback.com/blog/
www.spreadIE.com


Relevant Pages