'forEach index'에 해당되는 글 1건

SMALL


forEach문은 아래와 같이 활용한다.


<c:forEach items="${data}" var="변수값" varStatus="status">

<td>

${status.current} 현재 for문의 해당하는 번호

${status.index} 0부터의 순서

${status.count} 1부터의 순서

${status.first} 첫 번째인지 여부

${status.last} 마지막인지 여부

${status.begin} for문의 시작 번호

${status.end} for문의 끝 번호

${status.step} for문의 증가값

</td>

</c:forEach>

${status.current} 현재 for문의 해당하는 번호

${status.index} 0부터의 순서

${status.count} 1부터의 순서

${status.first} 첫 번째인지 여부

${status.last} 마지막인지 여부

${status.begin} for문의 시작 번호

${status.end} for문의 끝 번호

${status.step} for문의 증가값


사용 하시면 됩니다!

LIST
블로그 이미지

SeoHW

,