$(document).ready(function () { //menu /*$('.menu li').mouseover(function () { //$(this).children('.s-menu').stop().slideDown(); $(this).children('.s-menu').show(); }) $('.menu li').mouseout(function () { //$(this).children('.s-menu').stop().slideUp(); $(this).children('.s-menu').hide(); }) $('.s-menu').mouseover(function () { $(this).show(); }) $('.s-menu').mouseout(function () { $(this).hide(); })*/ //$('.search-label').mouseover(function () { // $('.search-box').show(); //}) //$('.search-label').mouseout(function () { // $('.search-box').hide(); //}) //$('.search-box').mouseover(function () { // $('.search-box').show(); //}) //$('.search-box').mouseout(function () { // $('.search-box').hide(); //}) $('.search-label').click(function () { $_tr = $('.search-box'); if ($_tr.is(":hidden")) { $_tr.show(); } else { $_tr.hide(); } }) $('.s-end').click(function (){ $('.search-box').hide(); }) //The distance between the pages of the anchor jump control $(".gotop").click(function () { $("html,body").stop().animate({ scrollTop: 0 }, 800); return false; }); $('.header-m .menu').click(function () { $('.main').addClass('bd-fix'); $('.header-m').addClass('bh-fix'); $('.m-menu').addClass('m-menu-fix'); }) $('.m-menu .bgs').click(function () { $('.main').removeClass('bd-fix'); $('.header-m').removeClass('bh-fix'); $('.m-menu').removeClass('m-menu-fix'); }) $('.m-menu .box .title img').click(function () { $('.main').removeClass('bd-fix'); $('.header-m').removeClass('bh-fix'); $('.m-menu').removeClass('m-menu-fix'); }) $('.f-m-menu-i').click(function () { if ($(this).next('.f-m-menu-c').is(":hidden")) { $(this).parent().addClass('on').siblings().removeClass('on'); $('.f-m-menu-c').hide() $(this).next('.f-m-menu-c').show(); } else { $(this).parent().removeClass('on'); $(this).next('.f-m-menu-c').hide(); } }) }) $(window).scroll(function () { if ($(window).scrollTop() > 0) { $('.header').addClass('cg'); } else { $('.header').removeClass('cg'); } });