yexinw


document.getElementById(\'selectid\').value

获取下拉框选中的文本:

document.getElementById(\'selectid\').options[document.getElementById(\'selectid\').selectedIndex].text

************************************************************************************************************************************

var selectObj=document.getElementById("下拉列表id");
下拉框选中项的文本
var selectOptionText= selectObj.options[selectObj.selectedIndex].innerText;
下拉框选中项的值
var selectOptionValue=selectObj.options[selectObj.selectedIndex].value;

分类:

技术点:

相关文章:

  • 2022-01-10
  • 2021-12-10
  • 2021-12-04
  • 2021-12-09
  • 2021-06-19
  • 2021-12-10
猜你喜欢
  • 2022-12-23
  • 2021-03-29
  • 2022-12-23
  • 2021-12-10
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案