Welcome Guest, Not a member yet? Register   Sign In
How to Maintain two sessions in single site....
#11

[eluser]MASS MASS[/eluser]
Hi tonanbarbarian.....

Already i got solution......

iam using session ........

$this->session->unset_userdata('user_id');

This is inbuilt library function..........

Thank you for great support (xwero.. esra.. tonanbarbarian.. Peter.. Ivanov..)
#12

[eluser]Riju Francis[/eluser]
I am creating session variables during login (using Freakauth - ci_sessions). In my application, I also need to store other variables in the session. But once that is done, the login variables in session cannot be retrieved and the login session expires.
Has anyone encountered this issue and been able to solve it?
#13

[eluser]jegbagus[/eluser]
hello mas mas, i got the same problem with your.
it got me stress all day.

this is my case.

i want to create two different session on CI. let say it Chart session and login state session. both of them use encrypt cookies value. i sparated them because they have a different live time. chart session must be live far longer than login state session. when i create First session from auto load library, it going well. but when i try to initialize another session, error happen.
I try to create a new session object, so i can always control it from my library. Not become one with CI instance.


Code:
$sess = new $CI_Session();

the error occur because CI won`t load encrypt library for another session library. So when i try to initialize a new session class, it don`t get encrypt library load to them. but if we don`t use encrypt session cookies, everything going well.
i`m sorry for my noobs question. i used to use java for programing. so i still have a java minded oop programing style.

any suggestion. for my problem?
best regard.
#14

[eluser]Dam1an[/eluser]
@mass Mass: Remember that you need to be careful as the CI sessions are encrypted, and can only have a maximum of 4K of data, so you may run into problems if you're shopping cart gets too big
#15

[eluser]paulon[/eluser]
just want to ask how to destroy a session cache when my browser close or terminate, or should i ask how to clear my session cache when i open a site for the first time.?


what happens here is that i got a site then when i log-in then i close/terminate the browser
and when i open again a browser/site i keeps me login.. witch is not appropriate for my site. what i want is when i close the browser with a login status, then if i reopen my site a want a logout status... thanks in advance... ^_^ and meri xmas to all...




Theme © iAndrew 2016 - Forum software by © MyBB