X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (https://forum.x-cart.com/forumdisplay.php?f=20)
-   -   Making it so they don't have to re-login everytime (https://forum.x-cart.com/showthread.php?t=2752)

Jon 05-17-2003 07:57 PM

Making it so they don't have to re-login everytime
 
I have some visitors complaining about having to re-login everytime they come back.

How difficult is it to keep them logged in until they log out. Maybe set a cookie that gets read upon return and creates the session?

Eddie Hillegers 05-18-2003 07:12 AM

Sorry i can not help you with a solution, but i would be verry carefull
with this. What happens if somebody stays logged in at the office or
such? Especially when you store creditcard information it can lead to
verry unpleasant situations. Who will be responsible if other people
start bying on his account?

Cheers Eddie

Jon 05-18-2003 07:43 AM

Yup, I understand the possible ramifications.

I NEVER store credit card information on my records, I just don't want that responsibility, and the user takes responsibility for their account in our terms of service. :wink:

funkydunk 05-18-2003 10:50 PM

If you change inlcude/check_useraccount.php: from

Code:

session_register("login");
session_register("login_type");


to

Code:

session_set_cookie_params(15552000);
session_register("login");
session_register("login_type");


That will save their session for 6 months - but I would warn against it for all the same reasons as highlighted.

anoack 05-19-2003 06:47 AM

Would it be possible to add a check box next to the login box
[X] Remember my Password

?

Jon 05-20-2003 10:05 AM

That's a good idea, and then maybe have a javascript popup warning when they check it.

I'll work on this tonight and see what I can come up with, don't see why it wouldn't be doable.

anoack 05-20-2003 10:07 AM

Cool!!! Keep us updated on your progress. Something like that would be very usefull!

barabbas 05-21-2003 12:10 AM

yeah, that sounds really good, if you get the code for it, please share :)

Jon 05-22-2003 11:41 AM

session_set_cookie_params(15552000);

Adding that does not seem to work to keep sessions.

I can do the logistics of the checkbox, and what not, but I'm having difficulty getting it to set the extended cookie, and I need to do that first. :)

Jon 05-22-2003 12:11 PM

Quote:

Originally Posted by funkydunk
Code:

session_set_cookie_params(15552000);
session_register("login");
session_register("login_type");



Definitely doesn't work, any other thoughts?


All times are GMT -8. The time now is 11:09 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.