Form Based Authentication
| From: | Anson Smith | Date: | Thu, 01 Jan 1970 00:00:00 +0000 |
| Subject: | Form Based Authentication | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-88221@lists.php.net to get a copy of this message | ||
I am new to PHP and I am attempting to use some type of authentication in my
site.
My first page is a simple HTML form page with 2 fields username and passwrd.
that form is POST'ed to a 2nd page.
In the second page I start a session, and if $_POST["username"] is set I
Register a "authenticated_user" session variable. (This will be replaced by
an actual authenticate function).
Could Someone Explain why I have to submit my first form twice in order to
be considered authenticated.
Also any pointers to tutorials or samples of form based authentication would
be appreciated.
My Code is attached:
Attachment: [unknown/unknown] verify.php
Attachment: [unknown/unknown] verify.php