簡體   English   中英

Spring MVC和Tile集成

[英]Spring mvc and tiles integration

我想使用多個瓷磚

<beans:bean id="tilesConfigurer"
      class="org.springframework.web.servlet.view.tiles2.TilesConfigurer"
      p:definitions="/WEB-INF/tiles-defs/templates.xml" /> 

但無法理解應如何傳遞多個tile.xml文件

您需要執行以下操作:

<bean id="tilesConfigurer"
    class="org.springframework.web.servlet.view.tiles2.TilesConfigurer">
    <property name="definitions">
        <list>
            <value>/WEB-INF/tiles-defs/templates.xml</value>
            <value>/WEB-INF/tiles-defs/templates1.xml</value>
            ... Keep adding the no. of xml you want as values
        </list>
    </property>
</bean>

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM