03-20-2008, 03:08 PM
|
#9 (permalink)
|
|
The Acquainted
Join Date: Feb 2008
Posts: 119
Thanks: 17
|
I would suggest a bit different approach. What login should do? I suppose create a session/cookies, etc
So that's what I would prefer:
PHP Code:
$user = new Member('username','pass'); if ($user->auth()) //checks if the password and username are correct $user->login(); //sets the cookies, etc
or maybe put the auth() part inside the login() and make it return true or false if the username/pass are correct or not.
|
|
|
|