Re: PHP Authentication

From: Date: Fri, 30 Nov 2001 00:32:45 +0000
Subject: Re: PHP Authentication
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-76126@lists.php.net to get a copy of this message
On Fri, 30 Nov 2001 07:29, Hippie wrote: > I'm attempting authorise users from a MySQL database. The idea being, > that upon access to the page they input their username and password > and this is checked against a table from an SQL database. This page > needs to be completely server independant which means that I can't > make use of the $PHP_AUTH_USER as this relies on IIS or Apache to know > how to authorise to my knowledge. > > If anyone has any ideas on how to accomplish this I would be more than > interested to hear of them. Also, failing this being possible if I can > resort to checking it against Radius instead of SQL so any ideas on > that would be great as well. > > Hippie. The concept is simple - query the database for a record where username = supplied value and password = supplied value: if you get a record returned, you have a match and they can enter; if not, they aren't allowed in. You may need to pass the authorisation aacross scripts - you could use a cookie, hidden field, sessions.... -- David Robley Techno-JoaT, Web Maintainer, Mail List Admin, etc CENTRE FOR INJURY STUDIES Flinders University, SOUTH AUSTRALIA Useless Invention: Combs for bald-heads.

« previous php.general (#76126) next »