Reputation: 49843
I'm wondering if is there any way to remove all domain site cookies and sessions params.
somenthing like $this->session->destroy();
?
Upvotes: 1
Views: 22021
Reputation: 155
In CodeIgniter 4, If you want to delete all your session data along with index/key then you can use this:
$this->session->destroy();
Upvotes: 0
Reputation: 119
Just to note for applications where post destroying session, you want user to land on the index page where that point forward is taken care of the function, use bellow,
$this->session->sess_destroy();
redirect('');
Upvotes: 1