Struts2 标签遍历Map集合

Posted on 2013-04-22 10:13  IT_louis  阅读(129)  评论(0编辑  收藏  举报

<%@taglib uri="/struts-tags" prefix="s"%>
    <table>
    <s:iterator value="map.keySet()" id="id">
    <tr><td>
        <s:property value="#id"/></td>
        <s:iterator value="map.get(#id)">
            <td><s:property value="name"/></td>
            <td><s:property value="code"/></td>
        </s:iterator>
    </tr>
    </s:iterator>
    </table>

Copyright © 2024 IT_louis
Powered by .NET 9.0 on Kubernetes