网友回复
<!DOCTYPE html> <html> <head> </head> <body> <select id="test" name=""> <option value="1">text1</option> <option value="2">text2</option> </select> <script> // 1:拿到select对象: var myselect = document.getElementById("test"); // 2:拿到选中项的索引: ...
点击查看剩余70%