• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Form Action

 
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a jsp with a submit button which gets results to disply in a List from the action class. The action related with this submit button is an action class that fetches the results. The forward element in the mapping loads the same jsp page but along with the results appended in the same page somewhere below.

How can this be accomplished??
 
pie sneak
Posts: 4727
Mac VI Editor Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are we displaying just one set of results or do more and more results get listed each time the form is submitted?

At high level, either method will require:
1) Set the values in the ActionForm or to a scope level
2) Have the jsp check if the values exist in the ActionForm, and if so, display them
 
Ranch Hand
Posts: 415
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In the same jsp where u r planning to display the results give a conditional loop like logic:exists name="req attribute" isnide this iterate through the results else it wont enter..........

but in ur action class throw back to the same page via forward and that list should be in request scope r should form a part of ur actionform
 
reply
    Bookmark Topic Watch Topic
  • New Topic