<select id="slList" οnchange="selectShow()">
<option value="100">A</option>
<option value="200">B</option>
<option value="300">C</option>
<option value="400">D</option>
</select>
<input type="text" id="txtShow" />
<script>
window.οnlοad=selectShow;
function selectShow(){
document.getElementById("txtShow").value=document.getElementById("slList").value;
}
</script>
初级之input与seelct功能二合一,
最新推荐文章于 2022-04-07 16:05:00 发布