header image
Home arrow Tutorials arrow JavaScript arrow Javascript mouseover
Javascript mouseover
 


 


 

Have you ever needed to swap images for an menu?  You can use javascripts onmouseover  and onmouseout to make it happen

Just add the following code to your <img> tag

onmouseover="javascript:this.src='image url';"
onmouseout="javascript:this.src='image url';"

example:

<img src="on.jpg" onmouseover="javascript:this.src='off.jpg';"
onmouseout="javascript:this.src='on.jpg';">

Thats it your menu will now how the classic image rollover.


SEO what is it?
Most website are not designed to be search engine friendly.  Is your website one of them?