Sessions in Codeigniter -
i using sessions store data multi step form when user completes 3 sections of form information inserted in database. have built form user can go stage , modify information have submitted, thing though, values repopulate form stored in sessions if user leaves form page , goes elsewhere in website , returns form information still in form…is there better way this? want data destroyed if leave form…
thanks
assuming form exists in 1 controller , isn't spread across multiple ones, unset session values in __construct
of every other controller. (you extend base controller if have lots save hassle of adding functionality many.
that way if user visits section, values lost, providing remain within "form" can remain intact.
Comments
Post a Comment