Variables: Session vs. Client vs. Cookie
I have a couple of apps that have use a multi-step input form to input some complicated data. As the user goes through the steps the data is saved in a SESSION. variable (actually a struct in one case and an arrary of structs in the other) before being inserted into the DB at the end. It all works fine except that sometimes people get called away from their computer in mid task (or are otherwise distracted) and when they come back, their session has expired and their partially entered data is lost.
The actual data they are entering is not sensitive so I am considering saving the data in a cookie at each step using WDDX to store the complex variable. I'll test to see if the SESSION variable is missing and if it is, recreate it using the data in the cookie. If the full steps are competed successfully, both the SESSION.variable and the Cookie are destroyed.
1) Is there a better way to do this?
2) If I was starting again, is there preferred way to store the data temporarily until it is inserted into the DB?
Magnus
