FORD THĂNG LONG | BÁO GIÁ XE FORD | ĐẠI LÝ XE FORD HÀ NỘI
$("li.dropdown-submenu > a").on("click", function(){ $("li.dropdown-submenu").removeClass("open"); if($(this).parent("li.dropdown-submenu").hasClass("inuse")){ $(this).parents("li.dropdown-submenu").addClass("open"); $(this).parent("li.dropdown-submenu").removeClass("open"); $(this).parent("li.dropdown-submenu").removeClass("inuse"); $(this).siblings('ul.dropdown-menu').find("li.dropdown-submenu").removeClass("open"); $(this).siblings('ul.dropdown-menu').find("li.dropdown-submenu").removeClass("inuse"); } else { $(this).parents("li.dropdown-submenu").addClass("open"); $(this).parents("li.dropdown-submenu").addClass("inuse"); } return false; }); $("#wrapper-overlay").on("click", function(){ $("li.dropdown-submenu").removeClass("open"); $("li.dropdown-submenu").removeClass("inuse"); }); $('#menu li').hover(function() { var dropdown = $(this), menu = dropdown.find('li'); // Restore to default position menu.removeClass('off-right'); // Adjust if it's off the screen if( menu.is(':off-right') ) { dropdown.addClass('off-right'); menu.addClass('off-right'); } }); $('#prd-cate-list .sub-page > ul > li').hover(function () { $(this).children('ul').stop(true, true).delay(200).fadeIn(300); }, function () { $(this).children('ul').stop(true, true).fadeOut(300); }); $('#prd-cate-list').hover(function () { $(this).children('ul.sub-page').stop(true, true).delay(200).slideDown(300); }, function () { $(this).children('ul.sub-page').stop(true, true).slideUp(300); }); $('#prd-cate-list-detail .main-page > ul > li').hover(function () { $(this).children('ul').stop(true, true).delay(200).fadeIn(500); }, function () { $(this).children('ul').stop(true, true).fadeOut(500); }); if ($(window).scrollTop() != "0") $("#to-top").fadeIn("slow"); $(window).scroll(function () { if ($(window).scrollTop() == "0") $("#to-top").fadeOut("slow") else $("#to-top").fadeIn("slow") }); if ($(window).scrollTop() != "0") $("#vsidebar").fadeIn("slow"); $(window).scroll(function () { if ($(window).scrollTop() == "0") $("#vsidebar").fadeOut("slow"); else $("#vsidebar").fadeIn("slow"); }); $('#click-phone').hover(function() { $('#txtphone').removeClass('inline-display'); }); $("#to-top").click(function () { $("html, body").animate({ scrollTop: 0 }, "fast") });