select标签刷新后保持之前选择值

<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<select id="sequence" >
<option value=""></option> <option value="gread" <c:if test="${requestScope.sequence eq 'gread'}">selected="selected"</c:if> >年级</option> <option value="class" <c:if test="${requestScope.sequence eq 'class'}">selected="selected"</c:if>>班级</option> </select>

 

posted @ 2019-06-19 17:44  暗夜消辰  阅读(1829)  评论(0编辑  收藏  举报