I was under the impression that since I’m using the current version of jQuery, I could bind multiple events to live(). I’m trying to achieve a simple effect: fade down a picture when hovering, and then fade back up when mousing off of it. I have:
$(".previews").live("hover", function(){
$(this).fadeTo('normal', .3);
},function(){
$(this).fadeTo('normal', 1);
});
From every example I’ve seen, this should work. Right now, when I mouse over, it fades down, but not up again.
i dont think you can use
livewithhoverlike this,use something likehoveris just short hand formouseenterandmouseleavehttps://github.com/jquery/jquery/blob/1.4.4/src/event.js#L994-996