<c:choose>、<c:when>和<c:otherwise>在一起連用,可以實現Java語言中的if-else語句的功能。
用法:
<c:choose>
<c:when test="${detail[0].ordOutletsname != null && !empty detail[0].ordOutletsname}"> <!--判斷指定的字段不爲null 並且不爲空 -->
</c:when>
<c:otherwise> <!-- 否則-->
</c:otherwise>
</c:choose>