Comments, Suggestions and/or Feature Requests for the Soundevotion Competition.

Losing Session State

Losing Session State

Postby dilvie » Sun May 28, 2006 4:39 pm

Hi,

Any chance you could set a "remember me" checkbox so sessions won't time out if we don't want them to?
dilvie
Regular
Regular
 
Posts: 86
Joined: Tue May 16, 2006 4:40 am

Postby Sonicade » Sun May 28, 2006 6:36 pm

I had implemented automatic logins already but because I'm using PHP sessions it was expiring the sessions even though the cookie was still valid. So I have it removed it until I can get it working properly. It's in the works though.
User avatar
Sonicade
Compo Admin
Compo Admin
 
Posts: 773
Joined: Fri Mar 17, 2006 6:42 pm
Location: California, USA

Postby MickRip » Mon May 29, 2006 7:48 pm

If your existing session handling is done via a few core functions, you should considering replacing the native PHP session handling functions with your own. PHP sessions are heavily controlled in shared hosting environments, and either there's a problem with your code somewhere, or there's restrictions imposed by your hosting provider. The bottom line is that you have to re-login every time you use the page.

Use a combination of set_cookie and use a mysql table to store and validate your sessions. Randomise a session_id yourself and randomise a hashed password to stop session hijacking. This is the way I do it. It's not great though if the client has cookies turned off. :P
User avatar
MickRip
Regular
Regular
 
Posts: 32
Joined: Wed Apr 26, 2006 6:31 pm
Location: Newcastle, Australia

Postby Sonicade » Tue May 30, 2006 12:46 am

I have an idea that I'm going to try which will just remember the session id and automatically log the user back in.
User avatar
Sonicade
Compo Admin
Compo Admin
 
Posts: 773
Joined: Fri Mar 17, 2006 6:42 pm
Location: California, USA

Postby Sonicade » Wed May 31, 2006 10:19 pm

Give her another try. Automatic Logins reworked and online again.
User avatar
Sonicade
Compo Admin
Compo Admin
 
Posts: 773
Joined: Fri Mar 17, 2006 6:42 pm
Location: California, USA

Postby organic io » Thu Jun 01, 2006 9:05 am

Sonicade wrote:Give her another try. Automatic Logins reworked and online again.


it worked overnight at home...

however now that i'm at work and on a different IP, i can't login at all :(
User avatar
organic io
Compo Admin
Compo Admin
 
Posts: 1535
Joined: Thu Apr 06, 2006 11:55 am

Postby Sonicade » Thu Jun 01, 2006 4:56 pm

Hurray! Thanks for testing it dj_io. Logins are down again :( because my isp changed something in their mysql configuration. I have contacted them and am waiting for them to fix the problem.
User avatar
Sonicade
Compo Admin
Compo Admin
 
Posts: 773
Joined: Fri Mar 17, 2006 6:42 pm
Location: California, USA

Postby organic io » Fri Jun 02, 2006 8:55 am

looks like it's working for real this time. i stayed logged in for 2 days at home and now i can login at work also. i'll post on monday morning to let you know if it stuck at work too :)
User avatar
organic io
Compo Admin
Compo Admin
 
Posts: 1535
Joined: Thu Apr 06, 2006 11:55 am

Postby Sonicade » Fri Jun 02, 2006 2:55 pm

Alright! :D
The mysql problem was fixed so everything should be working normally.
User avatar
Sonicade
Compo Admin
Compo Admin
 
Posts: 773
Joined: Fri Mar 17, 2006 6:42 pm
Location: California, USA

Postby organic io » Fri Jun 02, 2006 4:05 pm

almost 8 hours later and i'm still logged in. looks like it's good to go!
User avatar
organic io
Compo Admin
Compo Admin
 
Posts: 1535
Joined: Thu Apr 06, 2006 11:55 am

Postby Sonicade » Fri Jun 02, 2006 10:42 pm

Good good :D
User avatar
Sonicade
Compo Admin
Compo Admin
 
Posts: 773
Joined: Fri Mar 17, 2006 6:42 pm
Location: California, USA

Return to Feedback / Requests

Who is online

Users browsing this forum: No registered users and 1 guest