Welcome Guest, Not a member yet? Register   Sign In
Documentation: 'Session' missing unset method
#1

[eluser]David Cassidy[/eluser]
Correct me if I am wrong, but it seems the unset_userdata() method has been overlooked and not included in the documentation.
#2

[eluser]llbbl[/eluser]
Destroying a Session

To clear the current session:
$this->session->sess_destroy();


That works pretty good. I think the sessions are deleted automagically after a certain timeframe.
#3

[eluser]Derek Allard[/eluser]
HarbingerKen, thanks. I added it some time ago into the copy of the userguide in the SVN, but it hasn't made its way into the main distribution yet (next version). So I just wanted you to know that this will be added, and thanks for contributing.
#4

[eluser]David Cassidy[/eluser]
[quote author="llbbl" date="1194601393"]Destroying a Session

To clear the current session:
$this->session->sess_destroy();


That works pretty good. I think the sessions are deleted automagically after a certain timeframe.[/quote]

I noticed the discrepancy in the documentation when a fellow Igniter asked a question regarding how to unset session userdata without destroying the session in the FreeNode IRC channel (#codeigniter). So, you see the point was not to destroy the entire session, which is done automatically, but just a custom session variable.

And thank you Derek for pointing out the addition. I wouldn't have thought to look in the SVN for it.
#5

[eluser]Michael Wales[/eluser]
I saw the same post and could have swore I saw it in the documentation. I went looking for it to respond but couldn't find it myself.

Turns out I was on my laptop (release version of CI) while my desktop runs the edge version.

At least we know I'm not going crazy.




Theme © iAndrew 2016 - Forum software by © MyBB