Login/Password Script

software development

#1

Hello fellow DreamHoster’s -

I have a couple of secure sights setup under my hosting with DH. The way they work right now is that when you go to one of these sights and try to enter, you are first prompted with a popup Username & Password box. If you enter everything correctly, obviously you’re let in. If you enter incorrect info, you get that DH default template page stating why you can’t get in.

The way this secure service works is all fine & dandy, but I’m hoping someone here can perhaps help me with a more streamlined design login process. The long & the short of it is that instead of a popup box appearing, I would like my members to be able to enter their Usernames & Passwords into custom designed form boxes (ie: like what you login to on this forum, on Yahoo, on Hotmail, etc.). You know, the 2 boxes - one for your ID and one for your password. But I have no clue how to go about this. I know how to make the buttons and whatnot, but I don’t know what kind of script to add or what URL I should be using for my ‘login’ button.

If anyone could provide some help, it would be appreciated. Thanks kindly.


#2

It depends on what it is you’re trying to protect. What DreamHost lets you setup automatically is done by the web server on each request. You can’t simply replace it with one script that asks for a username and password. You have to make sure all the other pages are scripted so that they check to make sure the visitor is logged in properly and has the right privileges. This is usually done with cookies. Uhm, heres a an example for Perl, thought its a bit advanced:

http://www.stonehenge.com/merlyn/WebTechniques/col61.html