Freemarker循环遍历

<html>
<head>
    <title>测试页面</title>
</head>
<body>
    学生列表:<br>
    <table border="1">
        <tr>
            <th>序号</th>
            <th>学号</th>
            <th>姓名</th>
            <th>年龄</th>
            <th>家庭住址</th>
        </tr>
        <#list stuList as stu>
        <tr>
            <td>${stu_index}</td>
            <td>${stu.id}</td>
            <td>${stu.name}</td>
            <td>${stu.age}</td>
            <td>${stu.address}</td>
        </tr>
        </#list>
    </table>
</body>
</html>

  

posted @ 2021-03-19 16:45  浅笑19  阅读(1380)  评论(0编辑  收藏  举报