Some Advanced Sign-Up Functionality

Hello -

Little obstacle - was wondering if somebody could help me out with -

I have created a users table for  my application.

When somebody 'signs up', I would like them to be logged in to the site automatically under their username and password that they just signed up with.

(Would also like to have a e-mail generated to be sent to the user - but that seems fairly straightforward - just run a php mail() script in the actionCreate() in my usersController file)

What I cannot seem to figure out is how to get my login form to register the variables that the user just used to sign up -

Any possible answers?

Thanks

if (validates()) :

http://www.yiiframew…er#login-detail

If I understood you correctly, in your 'signup' action you can do

Quote

$identity = new UserIdentity($login, $password);

$duration = 3600 * 24 * 30; // here goes the value you want

Yii::app()->user->login($identity, $duration);

Something like this, I think.