I am facing a problem related to a registration page which involves multiple steps. In every step there is a form and there are two buttons one to proceed to next step and another one to go back to previous step. So, if I click on the button proceed to next step then next form appears but if I click on the back button then I go back to the previous step where all the data which I filled should show.
Now my question is how to implement this with PHP? Whether to use Session variables to store the data and show them whenever needed or to use a table where all the data will be stored?
Thanks,
Mou
Whether to use Session or table
Moderator: General Moderators
- Christopher
- Site Administrator
- Posts: 13596
- Joined: Wed Aug 25, 2004 7:54 pm
- Location: New York, NY, US
- Kieran Huggins
- DevNet Master
- Posts: 3635
- Joined: Wed Dec 06, 2006 4:14 pm
- Location: Toronto, Canada
- Contact:
it depends on what you need. Clearly you can achieve this with using sessions or db.
If making orderingprocess or something I would recommend storing all in DB. This way you might collect valuable information to analyze...like on witch step people ditched ordering, if they passed contact and didn't finish, could contact them...etc etc.
Depends what you're doing and if you need to collect all data available.
If still go with sessions...don't forget to validate all data from each step passed! no just the current step.
If making orderingprocess or something I would recommend storing all in DB. This way you might collect valuable information to analyze...like on witch step people ditched ordering, if they passed contact and didn't finish, could contact them...etc etc.
Depends what you're doing and if you need to collect all data available.
If still go with sessions...don't forget to validate all data from each step passed! no just the current step.