I have the following jQuery function but i dont know why is it display again after i waived the hover. The concept is, if the class is exist remove them after that load the new menu (from 1.php), wait 1000 and add new classes. Its working fine, but after i move my mouse to other dierction the concept run again. Why?
$(document).ready(function () {
$("#cikkek").hover(function () {
$("div.navbar2").removeClass("visible");
$("div.logo-rotate").removeClass("logo-rotate2");
$("a.font-visibility").removeClass("font-visible");
$("div.block1").load("1.php");
setTimeout(function () {
$("div.navbar2").addClass("visible");
$("div.logo-rotate").addClass("logo-rotate2");
$("a.font-visibility").addClass("font-visible");
}, 1000);
});
});
hover, it will do the same thing when you un-hover. Did you meanmouseenter?