⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vboxlayout.jsp

📁 这是STRUTS1.2。6的开发包。。这是我从芝APACHE网站下下来
💻 JSP
字号:
<%@ page import="java.util.Iterator"%>
<%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles" %>

<%-- Layout component 
  Render a list on severals columns
  parameters : componentsList 
--%>

<tiles:useAttribute id="list" name="componentsList" classname="java.util.List" />

<%-- Normally, we should use the iterate tag to iterate over the list.
  Unfortunatelly, this doesn't work with jsp1.1, because actual iterate tag use a BodyContent
  and include do a flush(), which is illegal inside a BodyContent.
  Jsp1.3 propose a new tag mechanism for iteration, which not use BodyContent.
  Wait until jsp1.3 
  
<logic:iterate id="comp" name="list" type="String" >
  <tiles:insert name="<%=comp%>" flush="false" />
  <br>
</logic:iterate>  
--%>

<%-- For now, do iteration manually : --%> 
<%
Iterator i=list.iterator();
while( i.hasNext() )
  {
  String comp=(String)i.next();
%>
<tiles:insert name="<%=comp%>" flush="true" />
<br>

<%
  } // end loop
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -