How to break a foreach loop?
800332Nov 26 2004 — edited Sep 19 2008Hi guys,
How can I break a foreach loop if i got the following code:
<c:forEach items="${stuff.stuffPostingImages}" var="img" varStatus="imgstatus">
<c:if test="${img.sequence=='1'}">
<c:out value="${img.imagePath}" />
</c:if>
</c:forEach>
mean once img.sequence==1 then will print out then exit the loop. Please help, Thanks !
regards,
kmthien