Im trying to fix my mouseout event.
Ive got the element
<div id="dropdown"></div>
to show when Im hovering on it. But I want it to dissapear when theres a mouseout event on the ".page_item.page-item-2" element AND #dropdown element.
Here's my Jquery code (that dosen't fully work)
$(document).ready(function(){
$("#dropdown").css('display', 'none');
$(".page_item.page-item-2").hover(
function() {
$("#dropdown").fadeTo("fast", 1.0);
});
var s = $(".page_item.page-item-2").mouseout;
var b = $("#dropdown").mouseout;
if(s && b){
$("#dropdown").fadeTo("fast", 0.0);
}
});
Im sure theres a simple solution to this. Please help
if(s && b)code is only ran once when the page loads