<script> window.onload=function(){ var div=document.getElementById('content') var btn=div.getElementsByTagName('input') var div_d=div.getElementsByTagName('div') for (var i = 0; i < btn.length; i++) { btn[i].onclick=function () { for (var i2 = 0; i2 < div_d.length; i2++) { div_d[i2].style.display='none' } div_d[i].style.display='block'//这行报错 } } } </script>
添加回答
举报
0/150
提交
取消