Im currently building a very "lit-webshop"..and I whould like all my users to get a cart for the shopping, but the thing is that in my nudle the idea is to create a list-object containing all the products that the user wants to buy and then add that list somewhere, for instance to a session...but the problem is that a session usually ends within 30mins..and I know I can change this value, but the problem remains that after x-ammount of time the cart will get "dropped"....another aproach is to store the cart in a cookie...is this a safe and good way to go?...the second wat I though of is to store it temporary in a database-table and then simply link the UserID and the Cart with eah other..so for retriveing the correct cart i just whould do something like:
SELECT Cart FROM TemporaryCarts WHERE UserID = [the user ID]
Well to go back to the main-problem, whats the best approach to store the cart without makeing it drop after x-amount of time?
How whould you solve this?
Sorry if my english is all messed up...
Thanks in advance!
View Complete Post