Hello all. I am trying to make a function in jQuery that will change the SOURCE of an image. This is what I have so far but it does not work . How can this code be altered to change the source of an image???
//This works, but I want to try it in jQuery style function
//document.getElementById(imageName).src = imageSrc;
//This does not work, there is something wrong with imageName
The way I currently have my images is like this:
<a href="#" onmouseover="changeImage('home','./images/home_over.png');" onmouseout="changeImage('home','./images/home_under.png');">
<img id="home" name="home" src="./images/home_under.png" alt="HOME & UPDATES" />