I have the following situation in my MVC controller
for (String key : form.keySet())
redirectAttrs.addFlashAttribute(key, form.getFirst(key));
return "redirect:" + page;
page is /secure/admin/pages/userPreferences.jsp and I have a single username attribute added to the flash attributes
From the JSP page, how do I access that username flash attributes. But I have no idea of how!
I have tried both ${param.username} and ${username} but none worked. I tried to dump all ${param} and request attributes but found nothing in the JSP
Similar question: How to read flash attributes after redirection in Spring MVC 3.1? - the difference is that they want to read flash attributes from MVC controller rather than from JSP view