Struts 2.x Tags Examples

Struts 2.x Tags :: The form tags for easier development!

The Struts 2.x Tags can be used inside the form tag to access and provide an effective way to display action tags, radio button, checkbox, combobox, select tag, double select tags, updown select tags, date time pickers, etc.
Struts 2.x is a powerful framework which is used to develop web applications. It is under the management of apache organization and is available as open source. It provides easy and effective way to develop web applications based on MVC pattern. It makes easy to work with Servlet and JSP.
ACTION TAG:
This tag can be used to transfer the control to struts.xml and further to the action. Here in name=”test” the term within the double quotes refer to the name of action which can be found or written inside the struts.xml file.
By default the value of executeResult is false, in that case the action tag will not be executed. So
will not work if executeResult is not set to true.
We can also pass parameters within the action tag. e.g.:
oxyzium
RADIO BUTTON TAG:
This tag can be used inside a Struts 2.x form tag to get radio button select option.
CHECKBOX TAG:
This tag can be used inside a Struts 2.x form tag to get checkbox select option.
COMBOBOX TAG:
This tag can be used inside a Struts 2.x form tag to get combobox select option.
The attribute emptyOption can be set to true or false. See the effect on both changes in your program.
SELECT TAG:
This tag can be used inside a Struts 2.x form tag to get sengle/multiple select option.
The attribute multiple can be set to true or false. See the effect on both changes in your program.
DOUBLESELECT TAG:
This tag can be used inside a Struts 2.x form tag to get sengle/multiple select option.
The attribute emptyOption can be set to true or false. See the effect on both changes in your program.
UPDOWNSELECT TAG:
This tag can be used inside a Struts 2.x form tag to get sengle/multiple select in up and down direction.
DATETIMEPICKER TAG:
This tag can be used inside a Struts 2.x form tag to display date time select option.
Remember to include inside head tag to use the above tag.
Best Regards!!!