gpt4 book ai didi

java - struts中foreach的使用方法

转载 作者:搜寻专家 更新时间:2023-10-31 20:15:10 26 4
gpt4 key购买 nike

我在使用 forEach 的地方有这个 struts 代码-

<c:forEach items="${reviewList}" var="reviewListId">
<tr>
<td colspan="6" class="we_have"><c:out value="${reviewListId}" />
</td>
</tr>

我添加了这个标签库

<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c"%>

但是代替 forEach 标记显示的错误是-

According to TLD or attribute directive in tag file, attribute items does not accept any expressions

但是代替标签库它没有显示任何错误,这意味着它支持这个标签库但不知道为什么它不支持 forEach 标签。

最佳答案

尝试 <%@ taglib uri="http://java.sun.com/jsp/jstl/core prefix="c"%>

关于java - struts中foreach的使用方法,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8426812/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com