1
I made a function to log on to the system, however, when using the function sess_destroy()
to destroy the session, it does not allow you to display the set_flashdata()
. When I remove the function sess_destroy()
the set_flashdata()
works normally. Someone can give me a hint of what might be?
Controller:
public function logoff(){
$this->session->unset_userdata(array('user_id' => '', 'user_nome' => '', 'user_admin' => '', 'user_logado' => ''));
$this->session->sess_destroy();
set_msg('logoffok', 'Logoff efetuado com sucesso!', 'sucesso');
redirect('funcionario/login');
}
I put in my login method and it worked perfectly, Tanks ;)
– Andrew Maxwell