The xhtml provides all the basics that the simple theme provides and adds several features.
...
The xhtml theme uses the "wrapping" technique described by Extending Themes. Let's look at how the HTML tags are wrapped by a standard header and footer. For example, in the text.ftl
template, the controlheader.ftl
and controlfooter.ftl
templates are wrapped around the simple template.
...
The
controlheader.ftl
is referenced using ${parameters.theme} so that the code can be reused by the ajax theme.
XHTML Theme Header
Now let's look at the controlheader.ftl
and controlheader-core.ftl
. Again, these are split up for easy re-use with the ajax theme) contents:
Wiki Markup |
---|
{snippet:id=all|lang=xml|url=struts2/core/src/main/resources/template/xhtml/controlheader.ftl} |
...
While "after" isn't an attribute supported by any of the Struts Tags, if you are using FreeMarker Tags, Velocity Tags, or the param tag in any template language, you can add an after
parameter to place any content you like after the simple theme template renders. The after
attribute makes it easier to fine-tune HTML forms for your specific environment.
...
The xhtml head template extends the simple head template and provides an additional CSS that helps render the xhtml theme form elements.
...