Basically I want to change the image src to add -active.png
on hover.
So fb.png would become fb-active.png on hover, and fb.png when it\'s not hovering.
I use this script.. base on the script above... it just switch between the active and original image.
$("document").ready(function(){
$(".my_image").mouseenter(function(){
$(this).attr('src',function(index, attr){
return attr.replace(".png", "-active.png");
});
});
$(".my_image").mouseleave(function(){
$(this).attr('src',function(index, attr){
return attr.replace("-active.png",".png");});
});
});