Javascript Example
Screen shot
Javascript code to change image onmouseover and onmouseout.

<html>
<head>
<script type="text/javascript">

function image1()
{
document.getElementById("img").src ="button_effect2.jpg";
}
function image2()
{
document.getElementById("img").src ="button_effect1.jpg";
}

</script>
</head>
<body>
<a href="#">
<img id="img" border="0" src="button_effect1.jpg" onMouseOver="image1()" onMouseOut="image2()" />
</a>
</body>
</html>

You can download source code here