Re: [phplib] login page help From: giancarlo pinerolo (giancarlo <email protected>)
Date: 07/12/01

giancarlo pinerolo wrote:
>
> step 1
> activate default_authentication in your auth subclass ($nobody=true)
> step 2
> add user, auth, perm everywhere

No, maybe these two steps are optional.

But it took me a few months, after reading the docu and trying the
kris/test hundreds of times, to understand that 'default_authentication'
was not a 'weaker authentication scheme' but something the 99% of the
people would like.

It's having, always, the function of authentication at hand, even before
the user has authenticated himself *really*, and it's mostly necessary
when you want personalization, user preferences etc

Giancarlo

> step 3
> make this form
> <FORM action="/welcome_new_user.php?enter=yes" method=post>
> Login
> <INPUT name=username size=10 value="">
> Password
> <INPUT name=password type=password size=10 value="">
> <INPUT type=submit value="login"><BR>
> </FORM>
>
> step 4
>
> make welcome_new_user.php3 like this
> <?
> #normal includes and stuff here
> if ($enter):
> if ($auth->auth["uid"]=$auth->auth_validatelogin()):
> page_close();
> header("Location: ". $sess->url("$PHP_SELF"));
> else:
> $login_error="TRY AGAIN;
> endif;
> endif;
> ?>
> WELCOME NEW USER
>
> Step 5
> come back and tell me. This may be everything.
>
> Giancarlo
>

-- 
Abbestellen mit Mail an:   phplib-unsubscribe <email protected>
Kommandoliste mit Mail an: phplib-help <email protected>