参考:http://www.opensymphony.com/sitemesh/tags.html
SiteMesh有两个标签库分别为sitemesh-decorator.tld、sitemesh-page.tld
<decorator:head />
插 入原始页面(被包装页面)的head标签中的内容(不包括head标签本身)。
<decorator:body />
插入原始页面(被包装页面)的body标签中的内容。
<decorator:title [ default="..." ] />
插入原始页面(被包装页面)的title 标签中的内容,还可以添加一个缺省值。
<decorator:getProperty property="..." [ default="..." ] [ writeEntireProperty="..." ]/>
在标签处插入原始页面(被包装页面)的原有的标签的属性 中的内容,还可以添加一个缺 省值。
sitemesh文档中的例子很好理解:
The decorator: <body bgcolor="white"<decorator:getProperty property="body.onload" writeEntireProperty="true" />>
The undecorated page: <body onload="document.someform.somefield.focus();">
The decorated page: <body bgcolor="white" onload="document.someform.somefield.focus();">
注意,writeEntireProperty="true"表示插入为"属性=值"并会在插入内容前加入一个空格。