password protection for multiple folders...

I have 2 folders (usercp and admincp) here

atm i am using .HTAccess but the pop up login box is a pain so i need a in-page script that will allow access to a folder depending on user/pass

Any ideas?

True.

Tricky one if you want to continue using http authentication. You could, and this is messy, do it with a form and some JS. Basiccally forward the user to

http://<username_from_form>:<password_from_form>@lsajdalsdjasldj.com/

This means passwords will show up in your logs and their history and even intermediary proxy servers.

If you have PHP, ASP etc available then there are plenty of scripts available to do the job. I would assume that there are some Javascripts ones available too but wouldn’t know where unfortunately.

Regards.

Kaibigan

Take a look here for how to do password protection in php - http://uk2.php.net/features.http-auth