I am looking for a jQuery selector that has an 'either' selection. The thing is, I have a dropdown menu and want them to leave on 2 options.
Either when they leave the button or when they leave the menu that popped out.
When I use jQuery(".button, ul.menu").mouseleave
it will dissapear when I leave the button.
I want it to be different; at least 1 of the selectors HAS to be hovered to have the menu out.
How would I be able to do this?
<script>
jQuery(document).ready(function(){
jQuery(".button").mouseover(function(){
jQuery("ul.menu").stop().delay(600).fadeIn("fast");
});
jQuery("ul.menu, .button").mouseleave(function(){
jQuery("ul.menu").stop().fadeOut("fast");
});
});
</script>
Thanks!