Login Time Out

Hello,

How can I increase the login time out? I don’t know if time out is the correct word for that or maybe it’s the cache but I have a notes app and after a while that the user inserting his note and he wants to save he goes back to the login screen and he looses his notes.

Regards,

Dudunegrinhu

Find a place where CWebUser::login occurs in your app and change $duration to whatever you want.

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

I use the yii-user to manage my user and the login occurs in the login screen. If I put this code there is the duration lasts for the entire page or just for that screen?

I’m sorry for the dummy question but I’m still learning Yii.

As I can see, yii-user extension using rememberMeTime param to set session duration.

You can just set it in config file.