是否有Grails的GSP的方式來替換以下帶有內容的Grails GSP外部模板?
<tmpl:/templates/header />
<!-- tmpl namespace call is equivalent to <g:render template="/templates/header" /> -->
<!-- definition of inner content -->
<tmpl:/templates/footer />
與外部模板?從本質上講,這是一種進口的包裝外模板,
<outertemplate:templatename>
<!-- header will be rendered from outer template -->
<!-- definition of inner content -->
<!-- footer will be rendered from outer template -->
</outertemplate:templatename>
和外模板被一些沿着
<!-- definition of header content -->
<!-- placeholder or attr for inner content -->
<!-- definition of footer content -->
封裝在一個模板與兩個包裹內容系定義。 IIRC在JSF下有辦法做到這一點,但我無法在GSP下找到相應的等價物。
我不確定你在問什麼。模板可以呈現模板。 – 2013-03-26 21:29:59
你能詳細解釋一下你的問題嗎? – 2013-03-26 21:32:14
@詹姆斯麥克馬洪,你的問題太明確,你試圖做的明顯重構。我們需要知道tmpl tagLib先做了什麼。 – rimero 2013-03-26 22:11:53