Struts Section Index | Page 5
Struts Tip #7 - Use Multibox to manage checkboxes
Many applications need to use a large number of checkboxes to track options or selected items. To help with this, Struts provides the multibox control. It's quite handy but a little ...more
Struts Tip #4 - Formatting output with MessageResources
A common requirement of the presentation layer is to format information in a human-friendly way. While a numeral rendered as 1000000 works well for the software, most humans can't tu...more
Struts Tip #5 - Use coarse-grained ActionForms
The biggest hassle for any Struts developer can maintaining the #@$!% ActionForms. The ActionForm provides several important services to an application, since it is
a firewall, ...more
Struts Tip #6 - Use an array to capture multiple parameters
In a perfect universe, our users would happily subscribe to the One True Workflow. In every case, we could list some records, select a record to view or edit, and list some records a...more
Struts Tip #3 - Use LookupDispatchAction for a JavaScript-free dispatch
Many forms can be put to multiple uses. The fields we need to create a record are usually the same fields we use to update a record. Likewise, the same page can usually used to iden...more
Struts Tip #2 - Use DispatchAction to organize related operations
Any software application is defined by the things it can do for you. In a Struts Web application, the things an application does is usually defined by its action-mapping elements. An...more
Struts Tip #1 - Use an ImageButtonBean to represent an image button.
An endless source of aggravation is the HTML input image element. The specification says that browsers should treat this control like an image map. Unlike other buttons, it does not ...more
Using Map instead of String properties with ActionForm.
Using Map instead of String properties with ActionForm.
How do you use a Map object with ActionForm with Struts 1.1-b1?
Mr. Husted, in a message posted on the FAQS you said:
In Struts 1.1 beta, a...more
Handling errors in file upload with struts
handling errors in file upload with struts
I am using struts and have an upload.jsp and its associated
UploadForm.java and UploadAction.java. The jsp's form has
an enctype=multipart/form-data and ...more
JUnit with singletons What do people think about adding the functionality into JUnit to enable one to load and unload singletons during tests. This can be very helpful, if, for example, several possible states of the singleton that cannot be achieved in succession need to be tested. I've come up against it recently.
JUnit with singletons
What do people think about adding
the functionality into JUnit to
enable one to load and unload singletons
during tests. This can be very helpful,
if, for example, several po...more
Multiple params with html:link tag?
Multiple params with html:link tag?
How to code my Struts html:link tag such that I can apply multiple dynamic parameters?
For example, I want to achieve the following:
<a href="/DeptInfo/do...more
Getter and setter functions of form bean work properly. also using the iterator tag, i am able to show values on the jsp page. but when the user changes those values and the control goes to the action class, the values are not changed inside the list.
Passing values from a Collection to Action class
Hello Friends,
getter and setter functions of form bean work properly. also using the iterator tag, i am able to show values on the jsp page. but ...more
ActionForms and Value Objects - Repetition of Code?
ActionForms and Value Objects - Repetition of Code?
I was very excited to start using ActionForms and Struts' forms tag library in order to lower the amount of code needed to handle all the forms i...more
I have a set of EJBs written, I am planning to create a prototype based on struts/MVC concept and I need to use some of the Business Logic Beaans [entity/session beasn] in to prototype implementation, please ealaborate me on this like where exactly those ejb beans be implemented/plugged in to incorporate the business logic?
Struts with EJB
Hi All,
I have a set of EJBs written, I am planning to create a prototype based on struts/MVC concept and I need to use some of the Business Logic Beaans [entity/session beasn] in ...more
I'm trying to setup a form that will populate with the information about a user (their name, address, etc.) I'm having trouble with this because I don't really understand how the ActionFormBeans work.
The Life of An ActionForm
Hi,
I'm trying to setup a form that will populate with the information about a user (their name, address, etc.) I'm having trouble with this because I don't really unders...more