jstl 中select与foreach的使用

源码展示
<div class="control-group"> <label class="control-label">所属项目:</label> <div class="controls"> <form:select path="projectId" class="input-xlarge"> <c:forEach var="fullName" items="${fullNames}"> <option value="${fullName.id}" <c:if test="${fullName.id == outline.projectId }">selected="selected"</c:if>> ${fullName.fullName} </option> </c:forEach> </form:select> </div>
</div>
原文地址:https://www.cnblogs.com/person008/p/7070377.html