layout.jsp:  
<%@  page  contentType="text/html;charset=UTF-8"%>  
<%@  taglib  uri="http://struts.apache.org/tags-tiles"  prefix="tiles"%>  
<html><body>  
<p>  
<tiles:insert  attribute="body"  />  
</p>  
<p>这里要插入参数,用什么标签?</p>  
</body></html>  
 
index.jsp:  
<%@  page  contentType="text/html;charset=UTF-8"%>  
<%@  taglib  uri="http://struts.apache.org/tags-tiles"  prefix="tiles"  %>  
 
<tiles:insert  page="layout.jsp"  flush="true">  
           <tiles:put  name="body"  value="body.jsp"/>  
           这里要对应插入参数,用什么标签??  
</tiles:insert> 
ps:我想好像插入页面那样,用一个标签插入一个参数(字符串)

解决方案 »

  1.   

    ps再ps:以上问题解决,另问:tiles如何国际化?就是不同页面显示不同信息,那段信息如何做到国际化。
      

  2.   

    当然还是一般struts中的国际化方法,tiles没有什么例外的国际化方法。
      

  3.   

    楼上的,我的意思如下:layout.jsp:  
    <%@  page  contentType="text/html;charset=UTF-8"%>  
    <%@  taglib  uri="http://struts.apache.org/tags-tiles"  prefix="tiles"%>  
    <html><body>  
    <p>  
    <tiles:insert  attribute="body"  />  
    </p>  
    <p><tiles:getAsString name="test"/></p>  
    </body></html>  
     
    index.jsp:  
    <%@  page  contentType="text/html;charset=UTF-8"%>  
    <%@  taglib  uri="http://struts.apache.org/tags-tiles"  prefix="tiles"  %>  
     
    <tiles:insert  page="layout.jsp"  flush="true">  
               <tiles:put  name="body"  value="body.jsp"/> 
               <tiles:put  name="test"  value="abcdefg"/>          
    </tiles:insert> 
    我的目的是想“abcdefg”可以国际化请问能如何实现?