I am wondering the method needed to condense these lines of code. Basically when you roll over an image, an image of text below it fades in and out.
$("#2").hover(function(){
$('#two').stop().animate({"opacity": 1}, 600);
},function(){
$('#two').stop().animate({"opacity": 0}, 600);
});
$("#4").hover(function(){
$('#one').stop().animate({"opacity": 1}, 600);
},function(){
$('#one').stop().animate({"opacity": 0}, 600);
});
$("#5").hover(function(){
$('#three').stop().animate({"opacity": 1}, 600);
},function(){
$('#three').stop().animate({"opacity": 0}, 600);
});
$("#6").hover(function(){
$('#four').stop().animate({"opacity": 1}, 600);
},function(){
$('#four').stop().animate({"opacity": 0}, 600);
});
Thank you greatly in advance!