Here is the code that I'm thinking needs to be altered: var timer; $("#menu > li > a").hover(function(){ $(this).parent().children("ul").slideDown(); }, function(){ var list = $("#menu ul:visible"); timer = setTimeout(function(){ list.slideUp(); },200); });
$("#menu > li > ul > li").hover(function(){ clearTimeout(timer); }, function(){ var list = $("#menu ul:visible"); timer = setTimeout(function(){ list.slideUp(); },200); });