Hi, is there a way to retrieve the HttpServletResponse on AbstractWizardFormController, to add a cookie for exemple ?
Thks.
Printable View
Hi, is there a way to retrieve the HttpServletResponse on AbstractWizardFormController, to add a cookie for exemple ?
Thks.
cher Olivier,
you can grab the HttpServletResponse at many place in a wizard.
You can get it by overriding the method processCancel or processFinish.
Where exactly do you want to use a cookie manually ?
Olivier
I'd like to persist data in a cookie on every post to the wizard, not only when I cancel or finish it. But I don't see any method that can be overrided at this stage. Maybe an interceptor will be able to do this job ?
Have you tried to set sessionForm to true and let the command be automatically stored on session at each call to the controller. The command is then the storage area.
I only tested it on simple form and it really behaves as you would expect ...
Olivier
Yes, the point here, is that I would like to store the data in a cookie and not in the session, in order not to be server dependent. If a server crash, you loose the session, but the cookie still exists.