Developing high quality website requires
small tricks to be implemented. To make visually impressive
website you can change image on mouse over specially
buttons.
Its just a small code which make change of image on
mouseover. Mouseover on image given below:

(first copy code
in notepad then copy code from notepad ->paste in
editor)
Add this code in Head tag:
|
<script>
function change_image(a,target)
{ x=document.getElementById(a);
x.src=target;}
</script> |
Add this code in Body Tag:
<img src="web_developement.jpg"
width="92" height="67" id="image1"
onMouseOver="change_image('image1','programming.jpg')"
onMouseOut="change_image('image1','web_developement.jpg')"> |
Define your image path where required.
If you want to add this effect to more images
1. just keep changing ID of your image and pass this
ID to function.
2. Define the name of target image to be changed on
mouseover or mouseout.
3. Note that on mouseout we have to define default image
as target image because on mouseout we want our default
image back.
|