动态改变select的默认属性selected
枫若醉 2015-01-29 11:37:50 <select id="days" name="days" onchange= "cheak(this)">
<option value="3">前3天</option>
<option value="5">前5天</option>
<option value="7">前7天</option>
<option value="10">前10天</option>
</select>
<input type="button" class="form_chazhao" onclick="go()">
选择任意option的值,点击提交按钮后,页面跳转默认改变当前的selected,例如我选择前3天,在第一个option标签添加selected=selected,选择前5天就在前5天标签添加selected。用<script>写。求大神指导。