English 中文(简体)
春季提交和成功 观点问题?
原标题:Spring form submission and successView problem?
  • 时间:2011-03-08 01:01:00
  •  标签:
  • spring-mvc

(A silly question?)In springframework, the simpleFormController interface has a property called successView, but I am wondering how can I pass the submitted form information to this successView? The official tutorial has this:

return ModelAndView(new RedirectView(getSuccessView()));

当然,我可以从“成功.htm”这一“成功意见”中向另一个控制者补充另一个图表,但控制者如何能形成有助于形成最终看法的信息?

* 我认为,把大话引向主审意见也是错误的。

最佳回答

If you want to use a redirect for the success view, then you either need to add URL parameters to the redirect URI, or you need to put the data into the session, so that you can retrieve it when the redirected request arrives. If you don t want to do either of those things, then don t use a redirect.

顺便提一下,SimpleFormController已经过时,你确实没有使用,特别是如果你刚刚读完春。 你们是否使用旧的理论?

问题回答

暂无回答




相关问题
multi-staged form using spring

please forgive me for this stupid questions. I just started developing web application using spring yesterday. The project that i worked on, have a multi staged form, that require users to complete ...

Rewrite spring-security redirect URLs

I m trying to get Tuckey UrlRewriteFilter to tidy up URLs for my webapp. One problem I ve got is that when spring-security notices that an anonymous user is trying to access a protected resource it ...

Spring Advice - submitting a form

I am having serious problems with code I have written with Spring so I have decided to start from scratch and ask for advice. Here are my requirements: When the page first loads I need a list of ...

How to implement Logout feature using Spring Web Mvc

I am new to Spring Web MVC.. Can I get some example or online link that shows me how to implement logout feature using spring web mvc ? I don t want to use the in built feature of spring security (i....

Exception thrown after processing onSubmitAction

I am very new to Spring and I have a simpleFormController with 2 methods. referenceData() with is called when the page loads and onSubmitAction() which is called on the submit of a form. I am ...

热门标签