要求每行交替背景颜色,怎么做?
我也是刚学的,还有没有更好的办法
  <tr>
  <td>序号</td>
  <td>图片</td>
  <logic:present name="admin" scope="session">
  <td>编号</td>
  </logic:present>
  <td>类别</td>
  <td>名称</td>
  <td>价格</td>
  <td>库存</td>
  <td>热度</td>
  <td>商品描述</td>
  <td>操作</td>
  </tr> 
<!-- ************************************以上是表头************************************** -->

  <logic:present name="productlist" scope="request">
<logic:iterate id="product" name="productlist" scope="request" indexId="index"> 

<!-- 主要是这里不会 -->
<c:choose>
<c:when test="????">
<tr style="background-color:yellow;">
</c:when>
<c:otherwise>
<tr>
</c:otherwise>
</c:choose>
<!-- ********* -->
<td><%=index+1 %></td>
<td>
<bean:define id="photo" name="product" property="photo" />
${ photo }
</td>
<bean:define id="pid" name="product" property="pid" />