jstl操作select

<select class="form-control" name="dataType" id="dataType"
                                        required>
                                        <option value="">请选择</option>
                                        <c:forEach var="type" items="${sysType}">
                                            <option value="${type.dataType}"
                                                <c:if test="${dictModel.dataType ==type.dataType}">
                                              selected
                                            </c:if>>${type.name}</option>
                                        </c:forEach>
                                    </select>

posted on 2016-04-09 10:00  以勤补拙  阅读(404)  评论(0编辑  收藏  举报