$(function () { ajax_bol = true; $(".submitForm").validate({ submitHandler: function (form) { submitForm(form); }, errorPlacement: function (error, element) { error.appendTo(element.parent()); } }); function submitForm(form) { debugger; if (ajax_bol == false) { return false; } ajax_bol = false; var postData = $(form).serialize(); var url = $(form).attr("action"); if (typeof (url) == "undefined" || url == "") { url = "/Tool/smly"; } $.ajax({ type: "POST", dataType: "json", url: url, data: postData, beforeSend: function () { }, success: function (result) { console.log(result); if (result.boo) { $(form)[0].reset(); swal({ title: "留言", text: "提交成功!我们会尽快反馈!谢谢!", type: "success", confirmButtonColor: "#e73329", confirmButtonText: "确定", }, function () { } ); ajax_bol = true; } else { ajax_bol = true; alert(result.msg); } } }); } var head = $(".headfixed").height(); if ($(window).width() > 640) { if (!$('body').hasClass('con_body')) { setTimeout(function () { new alan.scrollAnimate(); }, 50) } else { setTimeout(function () { new alan.scrollAnimate(); }, 50) } } // Handle click on toggle search button $('#toggle_search').click(function () { $('#search_form, #toggle_search').toggleClass('open'); return false; }); // Handle click on search submit button $('#search_form input[type=submit]').click(function () { $('#search_form, #toggle_search').toggleClass('open'); return true; }); // Clicking outside the search form closes it $(document).click(function (event) { var target = $(event.target); if (!target.is('#toggle_search') && !target.closest('#search_form').size()) { $('#search_form, #toggle_search').removeClass('open'); } }); $(".headfixed .menu_pcul .navli").hover(function(){ $('#search_form, #toggle_search').removeClass('open'); }) //返回顶部 function getTop() { var top = $(document).scrollTop(); if ($(document).scrollTop() > 150) { $(".right-flex").show(); } else { $(".right-flex").hide(); } setTimeout(getTop); } getTop(); //下滑头部出现背景 $(window).scroll(function () { var h = $(window).height(); var sc = $(window).scrollTop(); var bh = $("body").height(); if (sc > 0) { $(".headfixed").addClass('headerbgm') head = $(".headfixed").height(); } else { $(".headfixed").removeClass("headerbgm") head = $(".headfixed").height(); }; }); // 二级导航鼠标悬浮的时候加上背景 var b; b = $(document).scrollTop(); $(window).scroll(function () { b = $(document).scrollTop(); if (b <= 0) { $('.headfixed').removeClass("hheaderbgm"); } }) $(".headfixed").hover(function () { $(this).addClass("hheaderbgm"); }, function () { if (b <= 0) { $(this).removeClass("hheaderbgm"); } }); function _topStyle() { var _top = $(window).scrollTop(); // var _top2 = $('.headfixed').outerHeight(); var num = $(".offtop").length; for (var i = 1; i <= num; i++) { var _topi = $(".offtop").eq(i - 1).offset().top - $('.headfixed').height() - 80; if (_top > _topi) { $('.offtop').eq(i - 1).addClass('active'); } else { $('.offtop').eq(i - 1).removeClass('active'); } } } _topStyle(); $(window).on('scroll', _topStyle); // 底部二级导航显示/隐藏 var _winW = $(window).width(); var overscroll = window.innerWidth - document.body.clientWidth; if (_winW + overscroll <= 640) { $('.footer .footerphone-menu h3').on('click', function () { if (!$(this).hasClass("cur")) { $(this).addClass("cur").parent("li").siblings("li").find("h3").removeClass("cur"); $(this).next('.footer-subnav').slideDown().parent("li").siblings("li").find('.footer-subnav').slideUp(); } else { $(this).removeClass("cur"); $(this).next('.footer-subnav').slideUp() } }) } // 选项卡 function tabs(menu, cont, cur) { menu.hover(function () { var index = menu.index(this); $(this).addClass(cur).siblings().removeClass(cur); cont.children().eq(index).show().siblings().hide(); }); } /*单个js调用*/ $(document).ready(function () { //tab切换 tabs($('.product8 .tabBox .tab'), $('.product8 .contBox'), 'active'); }); function tabs1(menu1, cont1, cur1) { menu1.click(function () { var index1 = menu1.index(this); $(this).addClass(cur1).siblings().removeClass(cur1); cont1.children().eq(index1).show().siblings().hide(); }); } $(document).ready(function () { tabs1($('.soluton2 .spotBox .spot'), $('.soluton2 .rtBox'), 'active'); tabs1($('.soluton2 .tabBox .tab'), $('.soluton2 .contBox'), 'active'); tabs1($('.soluton2 .rctTli'), $('.soluton2 .rctBox'), 'active'); }); /*手机端导航*/ $('.headfixed .toggle_btn').on('click', function () { if ($(this).hasClass('on')) { $(this).removeClass('on'); $('.menu_list').removeClass('on'); $("body,html").css({"overflow": ""}); } else { $(this).addClass('on'); $('.menu_list').addClass('on'); $("body,html").css({"overflow": "hidden"}); } }); // 手机端二级导航下拉 $('.menu_list .mobile_ul .mobile_down').on('click', function () { if (!$(this).parent().hasClass("cur")) { $(this).parent().addClass("cur").parent("li").siblings("li").find(".head_tit").removeClass("cur"); $(this).parent().next('.head_subnav').slideDown().parent("li").siblings("li").find('.head_subnav').slideUp(); } else { $(this).parent().removeClass("cur"); $(this).parent().next('.head_subnav').slideUp() } }) $('.mobile_nav_box .link_tit .smobile_down').on('click', function () { if (!$(this).parent().hasClass("cur")) { $(this).parent().addClass("cur").siblings('.link_tit').removeClass("cur"); $(this).parent().next('.head-suba').slideDown().siblings('.head-suba').slideUp(); } else { $(this).parent().removeClass("cur"); $(this).parent().next('.head-suba').slideUp() } }) $(".head_subnav>a").click(function () { $(".mobile_nav_box").stop(true, true).slideUp(500); $(".toggle_btn_phone").removeClass('cur'); }) $(".newinfo1 .newinfo1_rli").eq(0).addClass('active'); $(".newinfo1 .newinfo1_rli").each(function (index, item) { $(".newinfo1 .newinfo1_rli").eq(index).hover( function () { $(".newinfo1 .newinfo1_rli").eq(index).addClass('active').siblings().removeClass('active'); } ) }) $('.videobox').on('click', function () { var u = navigator.userAgent; var url = $(this).attr('videoUrl'); $('.popvideobg').fadeIn(200); if (url.indexOf('http') == 0) { $('#videoPlayer').html('') } else { $('#videoPlayer').html('') if (u.indexOf('iPhone') > -1) { //苹果手机 document.addEventListener("WeixinJSBridgeReady", function () { $('#video')[0].play(); }, false); } else { $('#video')[0].play(); } } $("body,html").css({"overflow": "hidden"}); }) $('.close-video-btn').on('click', function () { $('.popvideobg').fadeOut(200); $('#videoPlayer').html(''); $("body,html").css({"overflow": ""}); }); $('.nav_menu ul').onePageNav(); /*手机端内页顶部导航下拉*/ var _winW = $(window).width(); var overscroll = window.innerWidth - document.body.clientWidth; if (_winW + overscroll <= 1024) { $('.nav_menu').click(function () { $(this).find('ul').stop(true, false).slideToggle(); }); } //数字滚动 if ($('.number').length > 0) { $('.number').countUp({ time: 1500 }); } $(".join1 .li").click(function () { var pop = $(".popupBox"); pop.find(".popData").html($(this).find(".popcont").html()); $(".shadow").show(); $(".popupBox").show(); $("body,html").css({ "overflow": "hidden" }); }) $(".close").click(function () { $(".shadow").hide(); $(".popupBox").hide(); $("body,html").css({ "overflow": "" }); }) $(".product4 .li").eq(0).addClass('active').siblings().removeClass('active'); // $(".product4 .li").eq(0).find('.about5 .about5-ul .dec').slideDown(); $(".product4 .li").hover(function() { $(this).addClass("active").siblings().removeClass("active"); }); // kf $(".right-close").click(function () { $('.right-flex').toggleClass("show"); if ($('.right-flex').hasClass("show")) { $('.right-flex').find("li").fadeIn() } else { $('.right-flex').find("li").fadeOut() } }); $(".right-flex .to-top").click(function () { $("html,body").animate({ "scrollTop": 0 }, 1000); }); $('a[href*=#],area[href*=#]').click(function() { if (location.pathname.replace(/^\//, '') == this.pathname.replace(/^\//, '') && location.hostname == this.hostname) { var $target = $(this.hash); $target = $target.length && $target || $('[name=' + this.hash.slice(1) + ']'); if ($target.length) { var targetOffset = $target.offset().top;//$('.headfixed').height()为顶部导航栏的高度 $('html,body').animate({ scrollTop: targetOffset }, 1000); return false; } } }); $(".select").click(function () { $(this).parent().siblings(".li").find(".itemBox").slideUp("fast"); if ($(this).siblings(".itemBox").is(":hidden")) { $(this).siblings(".itemBox").slideDown("fast"); var evt = new Object; if (typeof (window.event) == "undefined") { evt = arguments.callee.caller.arguments[0]; } else { evt = event || window.event; } evt.cancelBubble = true; } else { $(this).siblings(".itemBox").slideUp("fast"); //去除事件冒泡 var evt = new Object; if (typeof (window.event) == "undefined") { evt = arguments.callee.caller.arguments[0]; } else { evt = event || window.event; } evt.cancelBubble = true; } }); $(document).click(function () { $(".itemBox").slideUp("fast"); }); $(".itemBox .itemli").on("click", function () { $(this).parent().siblings(".select").text($(this).text()).end().slideUp("fast"); var txt = $(this).text(); // console.log(txt); $(this).parent().siblings('.select').val(txt); $(this).addClass('active').siblings().removeClass('active'); }); $(".select1").click(function () { $(this).parent().siblings(".li").find(".itemBox").slideUp("fast"); if ($(this).siblings(".itemBox").is(":hidden")) { $(this).siblings(".itemBox").slideDown("fast"); var evt = new Object; if (typeof (window.event) == "undefined") { evt = arguments.callee.caller.arguments[0]; } else { evt = event || window.event; } evt.cancelBubble = true; } else { $(this).siblings(".itemBox").slideUp("fast"); //去除事件冒泡 var evt = new Object; if (typeof (window.event) == "undefined") { evt = arguments.callee.caller.arguments[0]; } else { evt = event || window.event; } evt.cancelBubble = true; } }); $(document).click(function () { $(".itemBox").slideUp("fast"); }); $(".itemBox .dectli").on("click", function () { $(this).parents('.itemBox1').siblings(".select1").text($(this).text()).end().slideUp("fast"); var txt = $(this).text(); // console.log(txt); $(this).parents('.itemBox1').siblings('.select1').val(txt); $(this).addClass('active').siblings().removeClass('active'); $(this).parents('.itemli').siblings().find('.dectli').removeClass('active'); }); $(".liBox .icon-jt").click(function () { $(this).parent().siblings(".itemli").find(".itemBox").slideUp("fast"); if ($(this).siblings(".itemBox").is(":hidden")) { $(this).siblings(".itemBox").slideDown("fast"); var evt = new Object; if (typeof (window.event) == "undefined") { evt = arguments.callee.caller.arguments[0]; } else { evt = event || window.event; } evt.cancelBubble = true; } else { $(this).siblings(".itemBox").slideUp("fast"); //去除事件冒泡 var evt = new Object; if (typeof (window.event) == "undefined") { evt = arguments.callee.caller.arguments[0]; } else { evt = event || window.event; } evt.cancelBubble = true; } }); $('.product2 .listBox .titBtn .btn').on('click', function () { var part = $(this).parents(".listBox"); if (!part.hasClass('active')) { part.addClass('active').find('.list').stop().slideUp(300); } else { part.removeClass('active').find('.list').stop().slideDown(300); } }) $(".problem1 .ul .li").click(function () { $(this).toggleClass('active').siblings().removeClass('active'); $(this).find('.ans').slideToggle(); $(this).siblings().find('.ans').slideUp(); $(this).find('.doans').slideToggle(); $(this).siblings().find('.doans').slideUp(); }); $(".btn_menu").click(function () { if (!$(this).parents('.list').hasClass("active")) { $(this).parents('.list').addClass('active') $('.btn').text('隐藏过滤器'); var ths = $(this).siblings('.table').find('.hide').show(); var ths = $(this).siblings('.table').find('.hide'); console.log(ths); }else{ $(this).parents('.list').removeClass('active') $('.btn').text('显示过滤器'); var ths = $(this).siblings('.table').find('.hide').hide(); } }); $(".about6 .ul .li").eq(2).addClass('active').siblings().removeClass('active'); // $(".about6 .ul .li").eq(0).find('.about5 .about5-ul .dec').slideDown(); $(".about6 .ul .li").hover(function() { $(this).addClass("active").siblings().removeClass("active"); var imgUrl = $(this).attr('data-url'); // console.log(imgUrl) $(".about6 .bgm img").attr("src", imgUrl); }); $(".sli").click(function () { if (!$(this).hasClass('active')) { $(this).addClass('active'); } else { $(this).removeClass('active'); } }) var serbtn = $('.inputBox .icon-ssicon')[0]; var ipt = $('.inputBox .input')[0]; var cr = $('.inputBox .crlink')[0]; ipt.onfocus = function() { cr.style.display = 'block'; } ipt.onblur = function() { if (ipt.value === '') { cr.style.display = 'none'; } } serbtn.onclick =function(){ if(cr.style.display = 'none'){ cr.style.display = 'block'; } } $(document).click(function(e) { var target = $(e.target); if (!target.closest('.inputBox').size()) { cr.style.display = 'none'; } }) // swiper var inswp1Legth = $('.banner_swiper .swiper-slide').length; // console.log(inswp1Legth); if (inswp1Legth <= 1) { $('.banner_swiper .swiper-button-next').hide(), $('.banner_swiper .swiper-button-prev').hide(), $('.banner_swiper .swiper-button-pagination').hide(), $('.banner_swiper .swiper-wrapper').addClass('flexlf flexace') } else { $('.banner_swiper .swiper-button-next').show(), $('.banner_swiper .swiper-button-prev').show(), $('.banner_swiper .swiper-button-pagination').show(), $('.banner_swiper .swiper-wrapper').removeClass('flexlf flexace') function banner() { var inswp1 = new Swiper('.banner_swiper .swiper-container', { speed: 1500, loop: true, autoplay: 3000, watchSlidesProgress: true, watchSlidesVisibility: true, paginationClickable: true, pagination:'.banner_swiper .swiper-pagination', nextButton:'.banner_swiper .swiper-button-next', prevButton:'.banner_swiper .swiper-button-prev', }); $('.banner_swiper .swiper-container').mouseover(function(){ inswp1.stopAutoplay(); }) $('.banner_swiper .swiper-container').mouseout(function(){ inswp1.startAutoplay(); }) } banner() } var sec1Length = $(".section1 .contLi").length for (let i = 0; i < sec1Length; i++) { var ele = $(".section1 .contLi").eq(i).find(".swiper-container") this[".section1" + i] = new Swiper(ele[0], { observer: true, observeParents: true, loop: true, centeredSlides: true, simulateTouch: false, loopAdditionalSlides: 6, slidesPerView: 3, spaceBetween: 80, speed: 1000, pagination:ele.find(".swiper-pagination")[0], nextButton:ele.find(".swiper-button-next")[0], prevButton:ele.find(".swiper-button-prev")[0], breakpoints: { 640: { slidesPerView: 1, spaceBetween: 40, }, } }) } $(".section1 .tli").hover(function () { $(this).addClass("active").siblings().removeClass("active") $(".section1 .contLi").eq($(this).index()).addClass("active").siblings().removeClass("active") }) var sec2_1 = new Swiper('.swp1', { paginationClickable: true, speed: 1000, observer: true, observeParents: true, slidesPerView: 1, spaceBetween: 0, direction:'vertical', simulateTouch: false, // effect: 'fade', // fade: { // crossFade: true, // }, pagination: '.swp1 .swiper-pagination', nextButton: '.swp1 .swiper-button-next', prevButton: '.swp1 .swiper-button-prev', onSlideChangeEnd: function (swiper) { $('.section2 .tabli').removeClass('active').eq(swiper.activeIndex).addClass('active'); }, }); var sec2_2 = new Swiper('.swp2', { paginationClickable: true, speed: 1000, observer: true, observeParents: true, slidesPerView: 1, spaceBetween: 0, direction:'vertical', simulateTouch: false, // effect: 'fade', // fade: { // crossFade: true, // }, pagination: '.swp2 .swiper-pagination', nextButton: '.swp2 .swiper-button-next', prevButton: '.swp2 .swiper-button-prev', }); var sec2_3 = new Swiper('.swp3', { paginationClickable: true, speed: 1000, observer: true, observeParents: true, slidesPerView: 1, spaceBetween: 0, direction:'vertical', simulateTouch: false, // effect: 'fade', // fade: { // crossFade: true, // }, pagination: '.swp3 .swiper-pagination', nextButton: '.swp3 .swiper-button-next', prevButton: '.swp3 .swiper-button-prev', }); $('.section2 .tabli').hover(function () { if (!$(this).hasClass('active')) { $(this).addClass('active').siblings().removeClass('active'); sec2_1.slideTo($(this).index(), 1000, false); sec2_2.slideTo($(this).index(), 1000, false); sec2_3.slideTo($(this).index(), 1000, false); } }) var sec5Length = $(".section5 .swpli").length for (let i = 0; i < sec5Length; i++) { var ele2 = $(".section5 .swpli").eq(i).find(".swiper-container") this[".section5" + i] = new Swiper(ele2[0], { observer: true, observeParents: true, slidesPerView: 2.78, spaceBetween: 40, speed: 1000, pagination:ele2.find(".swiper-pagination")[0], nextButton:ele2.find(".swiper-button-next")[0], prevButton:ele2.find(".swiper-button-prev")[0], breakpoints: { 1000: { slidesPerView: 2.2, spaceBetween: 20, autoplay: 3000, }, 640: { slidesPerView: 1, spaceBetween: 10, autoplay: 3000, }, } }) } $(".section5 .tabli").hover(function () { $(this).addClass("active").siblings().removeClass("active") $(".section5 .swpli").eq($(this).index()).addClass("active").siblings().removeClass("active") }) var pro2 = new Swiper('.product2 .swiper-container', { speed: 800, slidesPerView: 3, spaceBetween: 30, autoplay: 3000, pagination:'.product2 .swiper-pagination', nextButton:'.product2 .swiper-button-next', prevButton:'.product2 .swiper-button-prev', paginationClickable: true, breakpoints: { 1000: { slidesPerView: 2, spaceBetween: 20, }, 640: { slidesPerView: 1, spaceBetween: 10, }, } }); $('.product2 .swiper-container').mouseover(function(){ pro2.stopAutoplay(); }) $('.product2 .swiper-container').mouseout(function(){ pro2.startAutoplay(); }) var pro3 = new Swiper('.product3 .swiper-container', { speed: 800, slidesPerView: 4, spaceBetween: 25, // autoplay: 3000, simulateTouch: false, pagination:'.product3 .swiper-pagination', nextButton:'.product3 .swiper-button-next', prevButton:'.product3 .swiper-button-prev', paginationClickable: true, breakpoints: { 1000: { slidesPerView: 3, spaceBetween: 20, autoplay: 3000, }, 640: { slidesPerView: 2, spaceBetween: 10, autoplay: 3000, }, } }); // $('.product3 .swiper-container').mouseover(function(){ // pro3.stopAutoplay(); // }) // $('.product3 .swiper-container').mouseout(function(){ // pro3.startAutoplay(); // }) var _winW = $(window).width(); var overscroll = window.innerWidth - document.body.clientWidth; if (_winW + overscroll <= 640) { var pro6 = new Swiper('.pro6_swp', { speed: 800, slidesPerView: 1, spaceBetween: 10, autoplay: 3000, pagination:'.pro6_swp .swiper-pagination', nextButton:'.pro6_swp .swiper-button-next', prevButton:'.pro6_swp .swiper-button-prev', paginationClickable: true, }); $('.pro6_swp').mouseover(function(){ pro6.stopAutoplay(); }) $('.pro6_swp').mouseout(function(){ pro6.startAutoplay(); }) var ab6 = new Swiper('.about6 .swiper-container', { speed: 800, slidesPerView: 2, spaceBetween: 15, autoplay: 3000, pagination:'.about6 .swiper-container .swiper-pagination', nextButton:'.about6 .swiper-container .swiper-button-next', prevButton:'.about6 .swiper-container .swiper-button-prev', paginationClickable: true, }); $('.about6 .swiper-container').mouseover(function(){ ab6.stopAutoplay(); }) $('.about6 .swiper-container').mouseout(function(){ ab6.startAutoplay(); }) } var ab3 = new Swiper('.about3 .swiper-container', { speed: 800, slidesPerView: 5, spaceBetween: 1, autoplay: 3000, simulateTouch: false, pagination:'.about3 .swiper-pagination', nextButton:'.about3 .swiper-button-next', prevButton:'.about3 .swiper-button-prev', paginationClickable: true, breakpoints: { 1000: { slidesPerView: 3, spaceBetween: 1, }, 640: { slidesPerView: 2, spaceBetween: 1, }, } }); $('.about3 .swiper-container').mouseover(function(){ ab3.stopAutoplay(); }) $('.about3 .swiper-container').mouseout(function(){ ab3.startAutoplay(); }) var ab5 = new Swiper('.about5 .swiper-container', { speed: 800, slidesPerView: 1, spaceBetween: 145, autoplay: 3000, effect: 'fade', fade: { crossFade: true, }, pagination:'.about5 .swiper-pagination', nextButton:'.about5 .swiper-button-next', prevButton:'.about5 .swiper-button-prev', paginationClickable: true, }); $('.about5 .swiper-container').mouseover(function(){ ab5.stopAutoplay(); }) $('.about5 .swiper-container').mouseout(function(){ ab5.startAutoplay(); }) var ab4_1 = new Swiper('.lfswp1', { paginationClickable: true, speed: 1000, observer: true, observeParents: true, slidesPerView: 1, spaceBetween: 50, // direction:'vertical', simulateTouch: false, // effect: 'fade', // fade: { // crossFade: true, // }, pagination: '.lfswp1 .swiper-pagination', nextButton: '.lfswp1 .swiper-button-next', prevButton: '.lfswp1 .swiper-button-prev', }); var ab4_2 = new Swiper('.lfswp2', { paginationClickable: true, speed: 1000, observer: true, observeParents: true, slidesPerView: 1, spaceBetween: 80, // direction:'vertical', simulateTouch: false, // effect: 'fade', // fade: { // crossFade: true, // }, pagination: '.lfswp2 .swiper-pagination', nextButton: '.lfswp2 .swiper-button-next', prevButton: '.lfswp2 .swiper-button-prev', }); var ab4_3 = new Swiper('.lfswp3', { paginationClickable: true, speed: 1000, observer: true, observeParents: true, slidesPerView: 1, spaceBetween: 50, // direction:'vertical', simulateTouch: false, // effect: 'fade', // fade: { // crossFade: true, // }, pagination: '.lfswp3 .swiper-pagination', nextButton: '.lfswp3 .swiper-button-next', prevButton: '.lfswp3 .swiper-button-prev', }); $('.about4 .rli').click(function () { if (!$(this).hasClass('active')) { $(this).addClass('active').siblings().removeClass('active'); ab4_1.slideTo($(this).index(), 1000, false); ab4_2.slideTo($(this).index(), 1000, false); ab4_3.slideTo($(this).index(), 1000, false); } }) var ab4_4 = new Swiper('.about4 .slist .swiper-container', { paginationClickable: true, speed: 1000, observer: true, observeParents: true, slidesPerView: 3, spaceBetween: 40, simulateTouch: false, autoplay: 3000, pagination: '.about4 .slist .swiper-container .swiper-pagination', nextButton: '.about4 .slist .swiper-container .swiper-button-next', prevButton: '.about4 .slist .swiper-container .swiper-button-prev', breakpoints: { 640: { slidesPerView: 2, spaceBetween: 20, }, } }); $('.about4 .slist .swiper-container').mouseover(function(){ ab4_4.stopAutoplay(); }) $('.about4 .slist .swiper-container').mouseout(function(){ ab4_4.startAutoplay(); }) var sec2 = new Swiper('.section2 .molist .swiper-container', { paginationClickable: true, speed: 1000, observer: true, observeParents: true, slidesPerView: 3, spaceBetween: 10, simulateTouch: false, autoplay: 3000, pagination: '.section2 .molist .swiper-container .swiper-pagination', nextButton: '.section2 .molist .swiper-container .swiper-button-next', prevButton: '.section2 .molist .swiper-container .swiper-button-prev', breakpoints: { 640: { slidesPerView: 2, spaceBetween: 10, }, } }); $('.section2 .molist .swiper-container').mouseover(function(){ sec2.stopAutoplay(); }) $('.section2 .molist .swiper-container').mouseout(function(){ sec2.startAutoplay(); }) var _winW = $(window).width(); var overscroll = window.innerWidth - document.body.clientWidth; if (_winW + overscroll <= 1000) { var jo2 = new Swiper('.join2 .swiper-container', { speed: 800, slidesPerView: 1, spaceBetween: 10, autoplay: 3000, pagination:'.join2 .swiper-container .swiper-pagination', nextButton:'.join2 .swiper-container .swiper-button-next', prevButton:'.join2 .swiper-container .swiper-button-prev', paginationClickable: true, }); $('.join2 .swiper-container').mouseover(function(){ jo2.stopAutoplay(); }) $('.join2 .swiper-container').mouseout(function(){ jo2.startAutoplay(); }) } $(".soluton2 .proBox").click(function () { $(this).parents(".rct").toggleClass('active').siblings().removeClass('active'); $(this).parents(".rct").find('.proCont').slideToggle(); $(this).parents(".rct").siblings().find('.proCont').slideUp(); }); })