I am very new to cakephp,my application is basically online registration ,it includes two steps in registering,i have two forms to capture data.i want to start session from the first step of registration and i need to store all the forms data in session attributes. after submission of second form data,the session data should save in database. please explain me in steps to do the above task.
you need this https://github.com/jaredhoyt/cakephp-wizard
Steps to save a form data
1) Crate view of the Form 2)On submit of the first step call an action and save your data in session array using this->Session->write('var_name',$array); 3) now on second step of the form submit call the same action and but check fr the condition is this a final submit ,and also session is not empty add those data to the sessions also and then add tht whole session array into database using Insert operation cakePHP 4) after saving the data empty the session array