Note that there are some explanatory texts on larger screens.

plurals
  1. POSpring SimpleFormController onSubmit request parameters
    primarykey
    data
    text
    <p>I am using <code>SimpleFormController</code> in my application to handle form submisions. one thing i am missing is the request object that is passed <code>onSubmit(request,response..)</code> is a different one from the initial request object that is received by <code>formBackingObject(..)</code>.probably because it is again a new request from web.</p> <p>i just want to use the same parameters from request object in <code>onSubmit(..)</code> that i was able to access in <code>formBackingObject(..)</code>.</p> <p>it could be possible for me to store them in and pass thru hidden fields from jsp, but i am trying to get some elegant approach.</p> <p>is there any way to achieve this? </p> <p>EDIT:</p> <p>i am overriding </p> <pre><code>formBackingObject(HttpServletRequest request)` </code></pre> <p>and</p> <pre><code>onSubmit(HttpServletRequest request, HttpServletResponse response, Object command, BindException errors) </code></pre> <p>methods in my class.</p> <p>for the intial view <code>formbackingObject(..)</code> will be called and i will have some variables from the request object then if user submits the form <code>onSubmit(..)</code> will be called then i will have another request object which is different from the one i received in <code>formbackingObject(..)</code> . </p> <p>what i am asking is, is there any way of holding the initial 'request' parameters(<code>request.getParameter()</code> kind of...) so that i can use them in <code>onSubmit(..)</code> with out sending them back &amp; forth thru hidden fields ?'</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload