[ic] CGI Values quesion
lists at gmnet.net
Tue Apr 24 11:06:00 EDT 2007
On Tue, 2007-04-24 at 13:46 +0100, Kevin Walsh wrote:
> mail <lists at gmnet.net> wrote:
> > you have to stop part way through and "save for later"
> > if you "reload the survey" then it works fine.
> > but if you log out and/or clear out your cookies and log back in, the
> > only values that stick are the ones on the current question. you can
> > see that all your other answer values do get loaded (top of page)
> Session values are lost when you get a new session, which is what you
> are finding here.
> The way around it will be to either save the values in the UserDB, and
> have them auto-load when you next login, or save them elsewhere and
> load them back into the session yourself.
> If it's a questionnaire then you are probably saving the results into
> a table anyway. In that case, you could save the results every time you
> submit one of the forms, and load the results every time you "reload
> the survey". You'd probably want to get the user to log in and then
> use their username as part of the questionnaire key. If you have more
> than one questionnaire then you'll want to use the questionnaire name/ID
> as another part of the key, of course.
> You probably don't want to save questionnaire results into the userdb
> (depending upon your application, of course). If you do then you could
> use the "preferences" store, as explained here:
Thanks Kevin, I was just staring at it way to close. As soon as I backed
up a bit and took another view, I saw what I needed to do in order to
"reload" the values correctly. That is right, there is a table for the
answers that get saved and they are tied to a username.
More information about the interchange-users