Results 1 to 4 of 4

Thread: Previous information is lost when I submit a form

  1. #1
    Join Date
    Jan 2005
    Location
    Barcelona (Spain)
    Posts
    3

    Default Previous information is lost when I submit a form

    Hi all, I'm spanish, so sorry for my English.

    I have a little problem and I don't know what is the best solution, I have a form with input text, selects, textareas... etc, when I fill these fields and submit this form I go to a confirmation page. If I decide to cancel the operation in this page I come back to the previous form but all the information in the fields has dissapeared. With struts it was very easy to avoid this situation, but I don't know how to do this with spring.

    Thanks in advance,

    Juan M. Monreal

  2. #2

    Default

    Show as your JSP code and FormController code please.

  3. #3
    Join Date
    Dec 2004
    Location
    Amsterdam
    Posts
    15

    Default

    Assuming you're using a SimpleFormController or AbstractFormController, you might want to have a look at the 'sessionForm' property on these controllers.

    This keeps your command object in the session, which means that your form will be filled on your previous page.

    I hope that helps solving your problem, if not, please do as radone says

    Regards,
    Erik

  4. #4
    Join Date
    Jan 2005
    Location
    Barcelona (Spain)
    Posts
    3

    Default

    Thanks to you, erik and radone. The problem was in a bad use of the command object.

    Regards.

Similar Threads

  1. Replies: 4
    Last Post: Sep 1st, 2010, 01:38 AM
  2. Replies: 3
    Last Post: Jun 8th, 2010, 03:27 AM
  3. Replies: 13
    Last Post: Jun 27th, 2008, 09:16 AM
  4. Replies: 5
    Last Post: Dec 16th, 2004, 03:19 PM
  5. Replies: 9
    Last Post: Aug 25th, 2004, 10:57 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •