Jump to content

Archived

This topic is now archived and is closed to further replies.

TropicalBeach

How to password a Unix folder?

Recommended Posts

Hi,
Newbie here...

I wish to password a web folder to allow only a few chosen users to see the contents.
Eg. www.foo.com/2006

What Php code is needed?

Share this post


Link to post
Share on other sites
[!--quoteo(post=359649:date=Mar 29 2006, 08:19 AM:name=TropicalBeach)--][div class=\'quotetop\']QUOTE(TropicalBeach @ Mar 29 2006, 08:19 AM) [snapback]359649[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Hi,
Newbie here...

I wish to password a web folder to allow only a few chosen users to see the contents.
Eg. www.foo.com/2006

What Php code is needed?
[/quote]

you can do that with an sql database and have a login page. or you can use somethign as simple as a .htaccess file if you want.

.htaccess files just have to reside in the directory you want to protect (it will protect all subdirectories as well) and force the user to enter a user/pass before entering that dir.

Share this post


Link to post
Share on other sites
Are you talking about through linux or through php. In Linux you would need to use chmod to enable read/write permissions.

Your question however isn't particularely clear.

Share this post


Link to post
Share on other sites
[color=purple]I have a similar problem - I've just installed phpmyadmin on my webserver and now discover anyone can access my entire database.

Please help!!!!

I want phpmyadmin, but I want to add some security.

Thanks.  [/color]
Neo

Share this post


Link to post
Share on other sites
[url=http://httpd.apache.org/docs/2.2/howto/auth.html]Apache: Authentication, Authorization and Access Control[/url]

[url=http://us3.php.net/features.http-auth]HTTP authentication with PHP[/url]

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.