Re: [PHPLIB] Self registration From: Massimiliano Masserelli (negro <email protected>)
Date: 10/29/99

On Fri, Oct 29, 1999 at 04:34:43PM +0200, Kristian Köhntopp wrote:

 KK> If you want to offer access to a protected area with a drop-in form
 KK> as Auth does and if you want to present either the login form or the
 KK> registration form, you have to decide if the user has seen your site
 KK> before. A cookie is the only mechanism to allow that. This is how reg
 KK> mode operates.

Yes, I understand that. I think this is not the best solution, cause the
same user may access the site with more than one cpu/browser.
 
 KK> Alternatively you can use a page with default authentication and a
 KK> separate registration page accessible to everybody. That way you will
 KK> present default content to unregistered users and offer them a
 KK> location to go to for registration. This is standard form stuff and
 KK> needs no special support from Auth. After a user completes the
 KK> registration successfully, you should add the users credentials to
 KK> your session manually, and Auth should offer a method to do that
 KK> ($auth->authenticate($uid)). This function is missing and should be
 KK> written, so that you can terminate your own registration form like
 KK> if (validate_form()) { $uid = create_user(); $auth = new
 KK> Example_Auth; $auth->authenticate($uid); }

This is exactly what I did in the code I posted here. I'm sorry I wasn't
that clear in explaining its functionality.

Bye.

--
     Massimiliano Masserelli       |     URL:    http://www.interim.it/
     Internet Images S.r.l.        |     Tel:    +39-051-3390671
     vicolo Viazzolo, 3            |     Fax:    +39-051-557890
     40124 - Bologna - Italy       |
-------------------------------------------------------------------------------
A few hours grace before the madness begins again.
-
PHP3 Base Library Mailing List. Send messages to <phplib <email protected>>.
To unsubscribe, send "unsubscribe" to <phplib-request <email protected>> in
the body, not the subject, of your message.