Apr 15, 2015; 10:15
Jon Harris
[LP8.6] Implementing a "remember me"
Hi List
We are trying to implement a "members area" on a site, where returning visitors have to login to see this content. This is all working fine, but I have a session issue.
The client wants us to add a "remember me" checkbox on the login page. So rather than a 120 minute session, they get a 1 year session.
Setting up the session is fine, after authentication we do this:
var('mySession') = 'memberSession' ;
if( var('rememberme') ) ;
session_Start(-Name=$mySession,
-Expires=525949,
-UseCookie) ;
Session_addvar($mySession, 'rememberme') ;
else ;
session_Start(-Name=$mySession,
-Expires=120,
-UseCookie) ;
/if ;
Problem is when the visitor comes back , I have to start the session again (with a new expiry time) to see if the remember me has been set or not, then restart the session again? Should I use two sessions? They still need the logout box to kill the session.
What's a good way of achieving this.
Thanks for any pointers.
Jon Harris
#############################################################
This message is sent to you because you are subscribed to
the mailing list Lasso Lasso@lists.lassosoft.com
Official list archives available at http://www.lassotalk.com
To unsubscribe, E-mail to: <Lasso-unsubscribe@lists.lassosoft.com>
Send administrative queries to <Lasso-request@lists.lassosoft.com>
Apr 16, 2015; 07:56
Ke Carlton
Re: [LP8.6] Implementing a "remember me"
Apr 16, 2015; 05:38
Jussi Hirvi
Re: [LP8.6] Implementing a "remember me"