Struts2 Tag Guide

Version 1.1 by Ken McWilliams on 2012/03/02 19:30

The first place to look for tag information should always be the Tag Reference at struts.apache.org.

There are five categories of Struts2 tags (which can be clearly seen in the above mentioned Tag Reference):

  1. Data
  2. Form
  3. Control
  4. Non-Form U
  5. Ajax

Data tags are used to output data to a jsp, typical uses include displaying values collected by the action and displaying links to other actions.

Form tags can display data like Data tags as they can supply a default value, but are used to render html form elements.  Note: Struts2 Form tags render using a theme so if you find it difficult to lay out the page as you would expect I would recommend changing the theme to simple.