[Solved] Multi Page Losing Session Data

Manofstyle 16 Mar, 2012
I'm trying to create a budget form that will capture customer's name, email and all budgetting related items them put together a report if they're positive or negative monthly. I've figured out the javascript but one thing I'm having problems with is the session data.

So the entire process is 7 pages. 1st page is contact info, 2nd is income, etc.. I'm trying to keep it simple.

Anyway, Page 1 I created first name field with the field id fname. I can get it to carry the data over from page 1 to page 2 & 3 but when page 4 comes I can't pull the information from page 1 I use the php to call the fname field and it's empty.

Website:
http://www.garranteedsolutions.com/index.php?option=com_chronoforms&chronoform=BudgetPage1
Manofstyle 16 Mar, 2012
I think I solved this. Have to turn on Merge session data to keep fields moving forward in the session.
GreyHead 16 Mar, 2012
Hi Manofstyle,

As I think you've found the Data to Session and Session to Data actions will help with this BUT I also recommend that you save the data at each step in a complex form so that if the session times out the data can be recovered.

Bob
laurentmartin 24 Jun, 2012
Hi Greyhead,

How do you propose to process to save the data at every page ?

I am very interested in this too.

Thank you for your answer
GreyHead 24 Jun, 2012
Hi Laretnmartin,

Use a DB Save action and pass the record id on in the form data so that the next save updated the same record.

Bob
laurentmartin 24 Jun, 2012
Hi Greyhead,

Very interesting.

From your writting i shoud save to DB after every submit but how to make this is update the newt saving and not create a new record in the database ?

Regards
GreyHead 25 Jun, 2012
Hi laurentmartin,

pass the record id on in the form data so that the next save updated the same record.


You need to get the record ID the first time you save data and then add that to the form data for the next step. Adding it to the $form->data array before the 'Data to Session' action will do this.

Bob
laurentmartin 26 Jun, 2012
Hi Greyhead,

I am a bit lost

Can you illustrate with screenshot ?
GreyHead 01 Jul, 2012
Hi Laurent,

Please see this FAQ to get the id. If you add a hidden input with the name 'cf-id' to your form then the value should be carried forward OK.

Bob
This topic is locked and no more replies can be posted.