This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Struts Application Design Question re ActionForms

 
Ian Davies
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am new to Struts but understand the basics. However, I have a question regarding to the best practices of using Action Forms.
ActionForms are great for processing HTTP parameters typically read from a HTML form. However, would you say that it is a good idea to have some other properties of the ActionForm that are not related to the HTML form but are populated by the Action class and used by the page that the Action forwards to, i.e. it is essentially a method of passing values to a subsequent page as a result of some action being performed?
If this is not recommended, could someone please suggest some best practices for passing parameters from one page to another?
Many thanks,
Ian.
 
Eric Sexton
Ranch Hand
Posts: 133
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When I need to carry/pass values around I usually will just set a session or request attribute in the action. I don't know if it's right or wrong within Struts, but that's what I do.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic