The <cms:template> tag

This tag allows you to split a JSP page into elements which can be included into other JSP pages using the cms:include tag.

Attributes:

Name Description Required
element Specifies the name by which the template element is included by the cms:include tag. yes

Body:

Any HTML, JSP or JSTL code of your template.

Example usage:

A JSP template page holding two elements "head" and "foot". Please refer to the cms:include tag documentation on how to include template elements:

<cms:template element="head">
<html>
<body>

This is the template head.
<hr>

<!-- Main page body starts here -->
</cms:template>


<cms:template element="foot">
<!-- Main page body ends here -->

<hr>
This is the template foot.

</body>
</html>
</cms:template>