extends를 이용해서 끌어오면 된다.

<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE tiles-definitions PUBLIC
       "-//Apache Software Foundation//DTD Tiles Configuration 2.0//EN"
       "http://tiles.apache.org/dtds/tiles-config_2_0.dtd">

<tiles-definitions>

    <!-- Default Main Template -->
    <definition name=".mainTemplate" template="/WEB-INF/templates/main.jsp">
        <put-attribute name="title" value="Simple Tiles 2 Example" type="string" />
        <put-attribute name="header" value="/WEB-INF/templates/header.jsp" />
        <put-attribute name="footer" value="/WEB-INF/templates/footer.jsp" />
        <put-attribute name="menu" value="/WEB-INF/templates/menu.jsp" />
        <put-attribute name="body" value="/WEB-INF/templates/blank.jsp" />
    </definition>
 
    <definition name="index" extends=".mainTemplate">
        <put-attribute name="body" value="/WEB-INF/jsp/index.jsp" />
    </definition>

    <definition name="info/about" extends=".mainTemplate">
        <put-attribute name="body" value="/WEB-INF/jsp/info/about.jsp" />
    </definition>
    
</tiles-definitions>

[링크 : http://www.springbyexample.org/examples/simple-tiles-spring-mvc-webapp-tiles-xml-config.html

'프로그램 사용 > struts2 tiles' 카테고리의 다른 글

struts2 result type input  (0) 2014.05.19
struts2 result type  (0) 2014.05.17
struts2 / tiles 연동시 에러  (0) 2014.05.16
struts2 .action 확장자 변경하기  (2) 2014.05.14
strtus2 레퍼런스  (0) 2014.04.30
Posted by 구차니