Instead of mouseoutand mouseover, which fire even when you enter a child, you can use .hover(), for example:
$("#nav li").hover(function(){
$(this).find("a").addClass("hover").fadeIn();
}, function(){
$(this).find("a").removeClass("hover").fadeOut();
});
.hover()displays events mouseenterand mouseleavethat do not work when entering / exiting from them, which is what causes double animation in your current code.
It is not directly related to the question, but on the page you want to indicate some other problems, it is included in jQuery (the latest 1.4.x), then jQuery 1.2.6 is included later with version 1.5.1 the validation plugin ( which is now up to 1.7) . I would look at updating the validation plugin and removing jQuery 1.2.6, as this can cause headaches later (and a heavier page for users now).
source
share