需要下载
导入第二个包后不需要设置配置文件
jsp页面中
<%@ taglib prefix=“c” uri=“http://java.sun.com/jsp/jstl/core” %>
<%@ taglib prefix=“fmt” uri=“http://java.sun.com/jsp/jstl/fmt” %>
<c:forEach items="
l
i
s
t
"
v
a
r
=
"
l
i
s
t
"
>
<
t
r
a
l
i
g
n
=
"
c
e
n
t
e
r
"
>
<
t
d
>
{list}" var="list"> <tr align="center"> <td>
list"var="list"><tralign="center"><td>{list.id}
l
i
s
t
.
u
s
e
r
n
a
m
e
<
/
t
d
>
<
t
d
>
{list.username}</td> <td>
list.username</td><td>{list.pwd}
<fmt:formatDate type=“both”
value="
l
i
s
t
.
t
i
m
e
"
/
>
<
/
t
d
>
<
t
d
>
<
a
h
r
e
f
=
"
{list.time}" /> </td> <td><a href="
list.time"/></td><td><ahref="{pageContext.request.contextPath}/Update?id=KaTeX parse error: Expected 'EOF', got '&' at position 18: …ist.id}">修改</a>&̲nbsp; <a h…{pageContext.request.contextPath}/Del?id=${list.id}">删除
</c:forEach>
java中jsp页面foreach遍历输出的使用
最新推荐文章于 2022-09-03 01:13:50 发布