[eluser]guidorossi[/eluser]
Hi!
I'm trying to make my own auth library with all the things I want and removing the things I don't want or need...
I based my code taking things from some others libraries like ion and wolf...
I'm having some trouble with the "remember me" option...
Basically I've got on my config.php:
Code:
$config['sess_expire_on_close'] = TRUE;
Then on my auth library I load the session library on the controller, but on my log_in() function of the auth library I want to make the "sess_expire_on_close" FALSE if "rememberme" is TRUE:
Code:
if ($remember == TRUE)
{
$config['sess_expire_on_close'] = FALSE;
$this->ci->load->library('session', $config);
$this->remember_me($user->id);
}
but obviously as the session library was loaded in the controller, seems that I can't change the config...
How can I handle this?
have the session expire on close if the user don't want to be remembered and keep it if the user want to be remembered...
Thanks...