0
 $(function(){ $('#webs').mouseenter(function(){ $('#websitehov').fadeIn('slow'); }); $('#webs').mouseleave(function(){ $('#websitehov').fadeOut('slow'); }); }); 

I know there are a ton of questions on this but I've tried a number of them and still not working, I've tried different event handlers including .hover, .mouseover and .mouseenter. The image hover/hover out effect fires multiple times when it enters and whenever I move the mouse inside the image the two events start firing. I found one solution that stopped this :

(function(){ $('#webs').hover(function(){ $('#websitehov').fadeIn('slow') }, function() { }); }); 

but this only worked for the hover in and not for hover out because the empty function was the mouseout event handler, idk if you can override this?

4
  • using .hover() with a callback will be a good solution. Commented Dec 9, 2013 at 10:45
  • tried and same result, still flashing multiple times and firing every time you move the mouse and continues to fire one more time once you leave the area code: $(function(){ $('#webs').hover(function(){ $('#websitehov').fadeIn('slow'); }, function(){ $('#websitehov').fadeOut('slow'); }); }); Commented Dec 9, 2013 at 10:49
  • either craete a fiddle or post more codes including html and css Commented Dec 9, 2013 at 10:58
  • i found the problem, the image that fires when hovering over the first image goes infront of the other image so they're fighting Commented Dec 9, 2013 at 11:01

1 Answer 1

3

The only possible problem I can see is that of animation queuing, clear the animation queue before addition another one

$(function () { $('#webs').hover(function () { $('#websitehov').stop(true, true).fadeIn('slow'); }, function () { $('#websitehov').stop(true, true).fadeOut('slow'); }); }); 

Demo: Fiddle

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.