选择框在页面刷新后怎么保留所选择的选项
选择框数据通过表中数据加载,选择某一选项在同一窗口提交,在页面刷新后怎么保留所选择的选项
------解决方案--------------------举个例子
<select name= "d_id " onChange= "document.form1.submit(); "/>
<option selected= "selected " value= " "> 选择编号 </option>
<% while not rs_d.eof and not rs_d.eof
if did=rs_d( "d_id ") then
response.Write " <option value= "&rs_d( "d_id ")& " selected> "
else
%>
<option value= " <%=rs_d( "d_id ")%> ">
<% end if%>
<%=rs_d( "d_id ")%> </option>
<% rs_d.movenext :wend %>
</select>
------解决方案--------------------选中的值回传本页
------解决方案--------------------用request()进行判断
------解决方案--------------------没错,用地址栏的形式传过去就行了!
------解决方案-------------------- <HTML>
<HEAD>
<META NAME= "save " CONTENT= "history ">
<STYLE>
.sHistory {behavior:url(#default#savehistory);}
</STYLE>
</HEAD>
<BODY>
<INPUT class=sHistory type=text id=oPersistInput>
</BODY>
</HTML>
试试或者用cookie