js获取dropdownlist的text/value
2008-11-06 09:42
453 查看
//假设你的dropdownlist叫Select1
document.getElementById('Select1').options[document.getElementById('Select1').selectedIndex].value;//value值
document.getElementById('Select1').options[document.getElementById('Select1').selectedIndex].text;//text值
document.getElementById('Select1').options[document.getElementById('Select1').selectedIndex].value;//value值
document.getElementById('Select1').options[document.getElementById('Select1').selectedIndex].text;//text值
相关文章推荐
- 可编辑的下拉框,以及js获取DropDownList的Text和Value
- JS获取DropDownList的value值与text值.txt
- JS获取DropDownList的value值与text值的示例代码
- JS获取DropDownList的value值与text值的示例代码
- JS获取DropDownList的value与text值
- js 获取asp 控件DropDownList的选择值,及所有的text和value
- JS获取DropDownList的value值与text值的示例代码
- 可编辑的下拉框,以及js获取DropDownList的Text和Value
- 获取dropdownlist value text
- JS获取select-option-text_value
- 通过js获取DropDownList控件的Value值
- JS获取DropDownList的value值与text值
- js获取select的value或者text
- js取得dropdownlist的text,value[转]
- 通过js来获取select的全部值,包括id,text,value
- JS获取页面所有input type=“text”的ID和value
- 使用js获取下拉列表框<option>中的value和text的值
- JS获取DropDownList的value值与text值
- JS 获取select的value和text值
- 用JS如何獲得DropDownList所選Text和Value?