Welcome Guest, Not a member yet? Register   Sign In
CI session
#21

[eluser]lectrotext[/eluser]
The session cookie gets correctly set.

Code:
Name: contribute_session

Value: a:18:{s:10:"session_id";s:32:"3633ffe53135b7aab17c2468a59d72f5";s:10:"ip_address";s:10:"10.8.11.52";s:10:"user_agent";s:50:"Mozilla/5.0+(Windows;+U;+Windows+NT+5.1;+en-US;+rv";s:13:"last_activity";s:10:"1231528631";s:6:"userid";s:1:"7";s:7:"u_login";s:24:"[email protected]";s:7:"u_first";s:5:"James";s:6:"u_last";s:7:"Pozenel";s:7:"u_title";s:0:"";s:9:"companyid";s:3:"100";s:6:"unitid";s:4:"1028";s:6:"permid";s:1:"1";s:9:"u_confirm";s:1:"1";s:6:"c_name";s:11:"Macrovision";s:6:"p_desc";s:19:"Super+Administrator";s:6:"u_name";s:18:"AMG+Data+Solutions";s:6:"u_type";s:2:"B2";s:6:"t_name";s:15:"Location/Office";}fe05d1e58d06bd46903065764b3345a4

Domain: .allmediaguide.com

Path: /

Send for: Any type of connection

Expires on: Sunday, February 08, 2009 2:14:58 PM
#22

[eluser]lectrotext[/eluser]
What it isn't doing is picking up this session cookie on the next day.
#23

[eluser]Michael Wales[/eluser]
The stuff in the quote box was before I read your entire post (I didn't look at the AJAX call, I only looked at the config.php).

Do you have the session library autoloaded? My thinking is that you are changing the value within the Config class but that would not change the expiration variable within the Session class (since it only sets this within the constructor). Sure, you attempt to load the session library again, after you change the config, but the Loader class will just return the already existing instance of the Session class if it exists.

See where I am going? Does the session library exist somehow, prior to you loading it within the code snippet you pasted above?
#24

[eluser]lectrotext[/eluser]
No it is not autoloaded for exactly those reasons. And I rarely include it the controllers constructors. I destroy sessions when I get a bad logins as well. The Logged in process relies on their not being a cookie called contribute_session. I typically start most logged in checks with a get_cookie check. If I have a contribute_session cookie I then load the Session library, but it is usually empty of userdata and is as I described created as a new session.
#25

[eluser]lectrotext[/eluser]
My current thoughts are to re-generate the session by breaking apart the cookie as the session class already does in sess_read.
#26

[eluser]Laurentvw[/eluser]
I'm having the same problem as previous posters. The cookie changes each time the page is being (re)loaded.
Now, here might be the problem; I'm using Google Chrome. I tested it on IE and Firefox, and to my surprise it worked fine there.
Can anyone else (previous posters??) confirm this?

Not sure if my post is of any value, I just started exploring CI!
#27

[eluser]majidmx[/eluser]
First of all double check the time on your server, is it setup correctly or not.
I had the problem with cookies when my server was supposed to be on eastern time but it wasn't.
The reason for this is, whenever server wants to build a cookie on client side it is already expired. so each time CI tries to renew it.
And surprisingly it defers from browser to browser, some accept and some not.

If it wasn't the problem, try to increase the session expiration time in config.

Also check whether or not you have a $config['cookie_domain'] in your config files, which replaces the main cookie domain.

Also you can set a value for $config['cookie_domain'] , like :
Code:
$config['cookie_domain'] = '.mydomain.com'
#28

[eluser]Marc Arbour[/eluser]
Hi

Concerning the post above...

[quote author="majidmx" date="1232319005"]First of all double check the time on your server, is it setup correctly or not.
I had the problem with cookies when my server was supposed to be on eastern time but it wasn't.
The reason for this is, whenever server wants to build a cookie on client side it is already expired. so each time CI tries to renew it.
[/quote]

I confirm that this is a case resolution for these behaviors as well...

Thanks majidmx.

Marc




Theme © iAndrew 2016 - Forum software by © MyBB