Separated jstl from html + plus no math for you, artsy types
<c:set var="row" value="Even" /> <c:forEach items="${records}" var="field" varStatus="counter"> <c:choose> <c:when test="${row eq 'Odd'}"> <c:set var="row" value="Even" /> </c:when> <c:otherwise> <c:set var="row" value="Odd" /> </c:otherwise> </c:choose> <div class="class${row}"> sample text here </div> </c:forEach>
user1998260
source share