0
我想有一个div
改变了上卷另一个图像的src
,但我得到一个TypeError: 'null' is not an object.
的document.getElementById从元素
<div id="text" onmouseover="document.getElementById('button').src='pushed.png'">
Hello
</div>
<img id"button" src="unpushed.png"/>
你 – 2012-04-22 16:27:19
你错过了=的IMG id属性的意思是'ID = “按钮”'。 – 2012-04-22 16:27:30
为什么是鼠标移到一个不同的元件一样按下一个按钮上? – 2012-04-22 16:30:59