代码示例:(标识:dhtm_imagesource)
<html>
<head>
<script type="text/javascript">
function moveover()
{
document.getElementById('image').src="/static/demo/images/eg_bulbon.gif"
}
function moveback()
{
document.getElementById('image').src="/static/demo/images/eg_bulboff.gif"
}
</script>
</head>

<body>

<b>请把鼠标移动到图像上:</b><br />
<img id="image" src="/static/demo/images/eg_bulboff.gif"
onmouseover="moveover()"
onmouseout="moveback()" />

</body>
</html>
运行结果: