I'm leanring Spring MVC and doing a project. I'm using SimpleFormController, and couldn't find a way to get current HttpSession to add new attributes the session object. How can I access HttpSession in onSubmit()?
Thanks in advance,
Walker
I'm leanring Spring MVC and doing a project. I'm using SimpleFormController, and couldn't find a way to get current HttpSession to add new attributes the session object. How can I access HttpSession in onSubmit()?
Thanks in advance,
Walker
Hi,
try this:
Code:public ModelAndView onSubmit(HttpServletRequest request, HttpServletResponse response, Object command, BindException errors) throws Exception { HttpSession session = request.getSession(); ... }