0

我有这样的场景..

ArrayList<String> list1=new ArrayList<String>();
     list1.add("str1");
     list1.add("str2");
     list1.add("str3");

ArrayList<String> list2=new ArrayList<String>();
     list1.add("str1");
     list1.add("str2");
     list1.add("str3");
     .
     .// like this i have 10 lists
     .
    list10.


ArrayList<ArrayList<String>> AllLists=new  ArrayList<ArrayList<String>>();

    AllLists.add(list1);
    AllLists.add(list2);
      .
      .
    AllLists.add(list10);

in Struts Action Class 
   request.setAttribute("allLists",AllLists);

如何使用在 JSP 页面中显示此 Arraylist 值

<logic:iterator> and <bean:write>标签给我一些想法..

提前致谢...

4

1 回答 1

0
<logic:notEmpty name="allLists" indexId="idx">
  <logic:iterate id="value" name="allLists">
    <bean:write name="value"/> or ${value} with index ${idx}.
  </logic:iterate>
</logic:notEmpty>
于 2013-02-21T14:36:57.123 回答