1 2(function($){ 3// windows size 4var mouseover_tid = []; 5var mouseout_tid = []; 6var winWidth = 0; 7var winHeight = 0; 8function winSize(){ 9 if (window.innerWidth) 10 winWidth = window.innerWidth; 11 else if ((document.body) && (document.body.clientWidth)) 12 winWidth = document.body.clientWidth; 13 if (window.innerHeight) 14 winHeight = window.innerHeight; 15 else if ((document.body) && (document.body.clientHeight)) 16 winHeight = document.body.clientHeight; 17 if (document.documentElement && document.documentElement.clientHeight && document.documentElement.clientWidth) 18 { 19 winHeight = document.documentElement.clientHeight; 20 winWidth = document.documentElement.clientWidth; 21 } 22 if(winWidth<951){ 23 24 if($('.mobile-head-items').length<1 && $('.mobile-nav-items').length<1 && $('.mobile-cart-items').length<1){ 25 26 var mobileService='<div class="mobile-head-items"><div class="mobile-head-item mobile-head-home"><div class="title"><a href="/"></a></div></div><div class="mobile-head-item mobile-head-nav"><div class="title"></div><div class="main-content-wrap side-content-wrap"><div class="content-wrap"></div></div></div><div class="mobile-head-item mobile-head-language"><div class="title"></div><div class="main-content-wrap side-content-wrap"><div class="content-wrap"></div></div></div><div class="mobile-head-item mobile-head-search"><div class="title"></div><div class="main-content-wrap middle-content-wrap"><div class="content-wrap"></div></div></div></div>' 27 $('.head-wrapper').append(mobileService) 28 if($('body .aside').length>0){ 29 $('.mobile-head-items').append('<div class="mobile-head-item mobile-head-aside"><div class="title"></div><div class="main-content-wrap side-content-wrap"><div class="content-wrap"></div></div></div>') 30 } 31 /*if($('.mobile-contact').length<1 && $('.head-contact').length>0){ 32 var mobileContact='<div class="mobile-contact"></div>' 33 $('body').append(mobileContact) 34 }*/ 35 36 mobileTabContainer('.tab-content-wrap','.tab-title','.tab-panel','span','.tab-panel-content') 37 38 39$('.mobile-head-item').each(function(){ 40 $(this).find('.title').click(function(){ 41 if($(this).parents('.mobile-head-item').find('.main-content-wrap').length>0){ 42 var pItem=$(this).parents('.mobile-head-item') 43 if(!pItem.find('.main-content-wrap').hasClass('show-content-wrap')){ 44 pItem.find('.main-content-wrap').addClass('show-content-wrap') 45 pItem.find('.side-content-wrap').stop().animate({'left':'0'},300) 46 pItem.find('.middle-content-wrap').addClass('middle-show-content-wrap') 47 pItem.find('.side-content-wrap').append("<b class='mobile-ico-close'></b>") 48 49 pItem.siblings('.mobile-head-item').find('.main-content-wrap').removeClass('show-content-wrap') 50 pItem.siblings('.mobile-head-item').find('.side-content-wrap').stop().animate({'left':'-70%'},300) 51 pItem.siblings('.mobile-head-item').find('.middle-content-wrap').removeClass('middle-show-content-wrap') 52 pItem.siblings('.mobile-head-item').find('.side-content-wrap .mobile-ico-close').remove() 53 if($('body').find('.mobile-body-mask').length<1){ 54 $('body').append('<div class="mobile-body-mask"></div>') 55 } 56 57 } 58 else{ 59 pItem.find('.main-content-wrap').removeClass('show-content-wrap') 60 pItem.find('.side-content-wrap').stop().animate({'left':'-70%'},300) 61 pItem.find('.middle-content-wrap').removeClass('middle-show-content-wrap') 62 pItem.find('.side-content-wrap .mobile-ico-close').remove() 63 } 64 $('.mobile-body-mask').click(function(){ 65 $('.mobile-body-mask').remove() 66 $('.mobile-head-item .main-content-wrap').removeClass('show-content-wrap') 67 $('.mobile-head-item .side-content-wrap').animate({'left':'-70%'},300) 68 $('.mobile-head-item .middle-content-wrap').removeClass('middle-show-content-wrap') 69 $('.mobile-head-item .side-content-wrap .mobile-ico-close').remove() 70 71 }) 72 $('.mobile-ico-close').click(function(){ 73 $('.mobile-body-mask').remove() 74 $('.mobile-head-item .main-content-wrap').removeClass('show-content-wrap') 75 $('.mobile-head-item .side-content-wrap').stop().animate({'left':'-70%'},300) 76 $('.mobile-head-item .middle-content-wrap').removeClass('middle-show-content-wrap') 77 $('.mobile-head-item .side-content-wrap .mobile-ico-close').remove() 78 79 }) 80 81 } 82 }) 83}) 84 85$('.change-language .change-language-cont ').clone().appendTo('.mobile-head-item.mobile-head-language .main-content-wrap .content-wrap') 86$('.head-search').clone().appendTo('.mobile-head-item.mobile-head-search .main-content-wrap .content-wrap') 87$('.nav-bar .nav').clone().appendTo('.mobile-head-item.mobile-head-nav .main-content-wrap .content-wrap') 88$('.head-social').clone().appendTo('.mobile-head-item.mobile-head-social .main-content-wrap .content-wrap') 89$('.aside .aside-wrap').clone().appendTo('.mobile-head-item.mobile-head-aside .main-content-wrap .content-wrap') 90 91 92 93 94 95/*$('.head-contact').clone().appendTo('.mobile-contact')*/ 96 97 } 98$(document).ready(function(){ 99 $('#rev_slider_3_1 ul li').each(function(index){ 100 if((index+1)%2==0){ 101 $(this).removeClass('evenItem') 102 $(this).find('.tp-caption.itemImg').addClass('lfb').removeClass('lft').attr('data-x','700') 103 $(this).find('.tp-caption.itemTitle').attr('data-x','0') 104 $(this).find('.tp-caption.itemDetail').addClass('lfl').removeClass('lfr').attr('data-x','0') 105 $(this).find('.tp-caption.itemMore').attr('data-x','0') 106 } 107 108 }) 109 110 111 }) 112 } 113 114 //mobile end 115 else{ 116 117 118 $(document).ready(function(){ 119 120 121 122 123 124 $('.mobile-body-mask,.mobile-head-items,.mobile-nav-items,.mobile-cart-items,.mobile-tab-items,.mobile-contact').remove() 125 126 //nav 127$('.nav').children('li').each(function(){ 128 var te=$(this).children('a').children('em').text() 129 $(this).children('a').children('em').attr('data-hover',te) 130 }) 131 132 $('.nav li').each(function(index){ 133 if($(this).children('ul').length>0){ 134 if($(this).children('a').find('.nav-ico').length<1){ 135 $(this).children('a').append("<i class='nav-ico'></i>") 136 } 137 138 $(this).hover( 139 140 function(){ 141 142 var _self = this; 143 144 clearTimeout(mouseout_tid[index]); 145 146 mouseover_tid[index] = setTimeout(function() { 147 148 /* $(_self).children('ul').fadeIn();*/ 149 $(_self).addClass('li-hover'); 150 151 }, 50); 152 153 }, 154 155 function(){ 156 157 var _self = this; 158 159 clearTimeout(mouseover_tid[index]); 160 161 mouseout_tid[index] = setTimeout(function() { 162 163 /*$(_self).children('ul').fadeOut();*/ 164 $(_self).removeClass('li-hover'); 165 }, 50); 166 167 } 168 169 ); 170 171 } 172 173 }) 174 175 176 177 }) 178 179$(document).ready(function(){ 180 181 $('.items_content').each(function(){ 182 if($(this).find('li').length>1){ 183 184 $(".items_content").jCarouselLite({ 185 btnPrev: ".btn-prev", 186 btnNext: ".btn-next", 187 speed:100, 188 auto:false, 189 scroll:1, 190 visible:5, 191 vertical:true, 192 circular:false, 193 onMouse:true 194 });
195 } 196 197 }) 198 }) 199 200 } 201 202 203} 204$(function(){ 205 winSize(); 206 207$('.main .detail-wrap table').each(function(){ 208 if(!$(this).parent().hasClass('table_wrap')){ 209 $(this).wrap("<div class='table_wrap'><//div>") 210 var tableWidth=$(this).outerWidth() 211 var tabWrapWidth=$('.main').outerWidth() 212 if(tableWidth>tabWrapWidth){ 213 $(this).parent('.table_wrap').css('overflow-x','scroll') 214 }else{ 215 $(this).parent('.table_wrap').css('overflow-x','hidden') 216 } 217 } 218 }) 219 220 221}) 222$(window).resize(function() { 223 winSize(); 224 225$('.main .detail-wrap table').each(function(){ 226 if(!$(this).parent().hasClass('table_wrap')){ 227 $(this).wrap("<div class='table_wrap'><//div>") 228 var tableWidth=$(this).outerWidth() 229 var tabWrapWidth=$('.main').outerWidth() 230 if(tableWidth>tabWrapWidth){ 231 $(this).parent('.table_wrap').css('overflow-x','scroll') 232 }else{ 233 $(this).parent('.table_wrap').css('overflow-x','hidden') 234 } 235 } 236 }) 237 238 239}); 240 241})(jQuery); 242$(document).ready(function(){ 243 244 245}); 246 247 248 249 250//scroll 251(function($){$.fn.jCarouselLite=function(o){o=$.extend({btnPrev:null,btnNext:null,btnGo:null,mouseWheel:false,onMouse: false,auto:null,speed:500,easing:null,vertical:false,circular:true,visible:4,start:0,scroll:1,beforeStart:null,afterEnd:null},o||{});return this.each(function(){var b=false,animCss=o.vertical?"top":"left",sizeCss=o.vertical?"height":"width";var c=$(this),ul=$("ul",c),tLi=$("li",ul),tl=tLi.size(),v=o.visible;var TimeID=0;if(o.circular){ul.prepend(tLi.slice(tl-v-1+1).clone()).append(tLi.slice(0,v).clone());o.start+=v}var f=$("li",ul),itemLength=f.size(),curr=o.start;c.css("visibility","visible");f.css({overflow:"",float:o.vertical?"none":"left"});ul.css({position:"relative","list-style-type":"none","z-index":"1"});c.css({overflow:"hidden",position:"relative","z-index":"2",left:"0px"});var g=o.vertical?height(f):width(f);var h=g*itemLength;var j=g*v;f.css({width:f.width(),height:f.outerHeight()});ul.css(sizeCss,h+"px").css(animCss,-(curr*g));c.css(sizeCss,j+"px");if(o.btnPrev)$(o.btnPrev).click(function(){return go(curr-o.scroll)});if(o.btnNext)$(o.btnNext).click(function(){return go(curr+o.scroll)});if(o.btnGo)$.each(o.btnGo,function(i,a){$(a).click(function(){return go(o.circular?o.visible+i:i)})});if(o.mouseWheel&&c.mousewheel)c.mousewheel(function(e,d){return d>0?go(curr-o.scroll):go(curr+o.scroll)});if (o.auto) TimeID=setInterval(function(){ go(curr + o.scroll);},o.auto+o.speed);if(o.onMouse){ul.bind("mouseover",function(){if(o.auto){clearInterval(TimeID);}}),ul.bind("mouseout",function(){if(o.auto){TimeID=setInterval(function(){go(curr+o.scroll);},o.auto+o.speed);}})}function vis(){return f.slice(curr).slice(0,v)};function go(a){if(!b){if(o.beforeStart)o.beforeStart.call(this,vis());if(o.circular){if(a<=o.start-v-1){ul.css(animCss,-((itemLength-(v*2))*g)+"px");curr=a==o.start-v-1?itemLength-(v*2)-1:itemLength-(v*2)-o.scroll}else if(a>=itemLength-v+1){ul.css(animCss,-((v)*g)+"px");curr=a==itemLength-v+1?v+1:v+o.scroll}else curr=a}else{if(a<0||a>itemLength-v)return;else curr=a}b=true;ul.animate(animCss=="left"?{left:-(curr*g)}:{top:-(curr*g)},o.speed,o.easing,function(){if(o.afterEnd)o.afterEnd.call(this,vis());b=false});if(!o.circular){$(o.btnPrev+","+o.btnNext).removeClass("disabled");$((curr-o.scroll<0&&o.btnPrev)||(curr+o.scroll>itemLength-v&&o.btnNext)||[]).addClass("disabled")}}return false}})};function css(a,b){return parseInt($.css(a[0],b))||0};function width(a){return a[0].offsetWidth+css(a,'marginLeft')+css(a,'marginRight')};function height(a){return a[0].offsetHeight+css(a,'marginTop')+css(a,'marginBottom')}})(jQuery); 252 253 254 255 256 257 258$(function(){ 259 var full_height = function() 260 261 { 262 263 if($(window).height() > 590) 264 265 { 266 267 if($('body').length > 0) 268 269 { 270 271 $('.page-end').unbind().bind('click', function(){ 272 273 $("html, body").animate({ scrollTop: $('.foot-wrapper').offset().top }, 2000); 274 275 }).css({cursor: 'pointer'}); 276 277 } 278/* 279 $(window).bind('scroll', function(){ 280 281 footer_lock(); 282 283 }); 284 285 footer_lock(); 286*/ 287 } 288 289 } 290 291 full_height(); 292 293 $(window).resize(function(){ 294 295 full_height(); 296 297 }); 298 var mHeadTop=$('.nav-bar').offset().top 299 300 var $backToTopTxt="top", $backToTopEle = $('<span class="gotop"></span>').appendTo($("body")) 301 302 .text($backToTopTxt).attr("title", $backToTopTxt).click(function() { 303 304 $("html, body").animate({ scrollTop:0 }, 1000); 305 306 307 308 }), $backToTopFun = function() { 309 310 var st = $(document).scrollTop(), winh = $(window).height(); 311 312 (st > mHeadTop)? $backToTopEle.fadeIn(): $backToTopEle.fadeIn(); 313 314 if (!window.XMLHttpRequest) { 315 316 $backToTopEle.css("top", st + winh - 210); 317 318 } 319 320 321 322 }; 323 324 $(window).bind("scroll", $backToTopFun); 325 326 $(function() { $backToTopFun();}); 327 328 var $nav = $('.nav-bar'),$headerTop = $('.head-top'), navTop = $nav.offset().top, navH = $nav.outerHeight(),winTop_1=0,winWidth=$(window).width(), holder=jQuery('<div>'); 329 $(window).on('scroll',function(){ 330 var winTop_2 = $(window).scrollTop(); 331 holder.css('height',navH); 332 333 if(winTop_2>navTop && winWidth>980){ 334 holder.show().insertBefore($nav); 335 $nav.addClass('fixed-nav'); 336 $headerTop.addClass('fixed-top'); 337 }else{ 338 holder.hide(); 339 $nav.removeClass('fixed-nav'); 340 $headerTop.removeClass('fixed-top'); 341 } 342 343 if(winTop_2>winTop_1 && winWidth>980){ 344 $nav.removeClass('fixed-nav-appear'); 345 }else if(winTop_2<winTop_1){ 346 $nav.addClass('fixed-nav-appear'); 347 } 348 winTop_1 = $(window).scrollTop(); 349 }) 350 351//tab 352tabContainer('.tab-content-wrap','.tab-title','.tab-panel') 353 354}); 355 356 357 358$(document).ready(function(){ 359 360 361 362 363 364 /*ä¾§æ 产ååç±»*/ 365 $('.side-widget .side-cate li').each(function(){ 366 367 if($(this).find('ul').length>0){ 368 369 $(this).append("<span class='icon-cate icon-cate-down'></span>") 370 371 $(this).children('.icon-cate').click(function(e){
372 373 if($(this).parent('li').children('ul').is(':hidden')){ 374 375 $(this).parent('li').children('ul').slideDown(100); 376 377 $(this).removeClass('icon-cate-down').addClass('icon-cate-up'); 378 379 }else{ 380 381 $(this).parent('li').children('ul').slideUp(100); 382 383 $(this).removeClass('icon-cate-up').addClass('icon-cate-down'); 384 385 } 386 387 e.stopPropagation(); 388 389 }) 390 391 392 393 } 394 395 }) 396 if($('.side-widget .side-cate .nav-current').parents('ul').length>0 && $('.side-widget .side-cate .nav-current').find('ul').length>0) { 397 $('.side-widget .side-cate .nav-current').parents('ul').show() 398 $('.side-widget .side-cate .nav-current').parents('li').addClass("show_li") 399 $('.side-widget .side-cate .nav-current').parents('li.show_li').children('.icon-cate').removeClass('icon-cate-down').addClass('icon-cate-up') 400 $('.side-widget .side-cate .nav-current').children('ul').show() 401 $('.side-widget .side-cate .nav-current ').children('.icon-cate').removeClass('icon-cate-down').addClass('icon-cate-up'); 402 } 403 else if($('.side-widget .side-cate .nav-current').parents('ul').length>0 && $('.side-widget .side-cate .nav-current').find('ul').length<1){ 404 $('.side-widget .side-cate .nav-current').parents('ul').show() 405 $('.side-widget .side-cate .nav-current').parents('li').addClass("show_li") 406 $('.side-widget .side-cate .nav-current').parents('li.show_li').children('.icon-cate').removeClass('icon-cate-down').addClass('icon-cate-up') 407 } 408 else if($('.side-widget .side-cate .nav-current').parents('ul').length<1 && $('.side-widget .side-cate .nav-current').find('ul').length>0){ 409 $('.side-widget .side-cate .nav-current').children('ul').show() 410 $('.side-widget .side-cate .nav-current').children('.icon-cate').removeClass('icon-cate-down').addClass('icon-cate-up'); 411 } 412 413 414 $('.gm-sep,.trusted-partners-wrap ul , .nav-bar .nav-wrap ,.nav').contents().filter(function() { 415 return this.nodeType === 3; 416 }).remove(); 417 418 419 420 421 422 423 if($('.image-additional ul li').length>1){ 424 $('.image-additional ul').owlCarousel({ 425 autoplay:false, 426 loop:false, 427 margin:0, 428 autoplayTimeout:30000, 429 smartSpeed:180, 430 lazyLoad:true, 431 mouseDrag:true, 432 slideBy:1, 433 responsive: { 434 0: { 435 nav: false, 436 dots: true, 437 items:1, 438 }, 439 951: { 440 nav: true, 441 dots: false, 442 items:3, 443 444 } 445 } 446 }); 447 } 448 else{ 449 $('.image-additional ul li').addClass('single') 450 } 451 452 453 $('.goods-items').owlCarousel({ 454 autoplay:true, 455 loop:true, 456 margin:20, 457 dots: true, 458 autoplayTimeout:30000, 459 smartSpeed:180, 460 lazyLoad:true, 461 462 responsive: { 463 0: { 464 465 items:1, 466 slideBy:1 467 468 }, 469 321: { 470 471 items:2, 472 slideBy:2 473 474 }, 475 769: { 476 dots: false, 477 nav: true, 478 items:3, 479 slideBy:3, 480 } 481 } 482 483 }); 484 485 $('.index-choose-container .choose-items').owlCarousel({ 486 autoplay:true, 487 loop:true, 488 margin:20, 489 dots: true, 490 autoplayTimeout:30000, 491 smartSpeed:1000, 492 lazyLoad:true, 493 nav:true, 494 items:1, 495 slideBy:1, 496 497 498 }); 499 500 501 $('.banner_flexslider,.about-img,.main-banner').flexslider({ 502 animation:"fade", 503 direction:"horizontal", 504 animationLoop:true, 505 slideshow:true, 506 slideshowSpeed:7000, 507 animationSpeed: 600, 508 touch: true, 509 }); 510 /*$('.detail-panel,.main-product-item').find('img').parents('a').addClass('lightbox') 511 $('.lightbox,.pd-inq a').lightbox();*/ 512 $('.entry').find('img').parents('a').addClass('fancybox') 513 $("a.fancybox").fancybox(); 514 515 516 $('.inquiry-form .form-item').each(function(index){ 517 $(this).addClass('form-item'+(index+1)) 518 }) 519 var demo = $(".inquiry-form,.wpcf7-form").Validform({ 520 tiptype : 3, 521 showAllError : true, 522 ajaxPost : false 523 }); 524 demo.addRule([ 525 { 526 ele : "input.form-input-email", 527 datatype : "e", 528 nullmsg:"Please enter a valid email address", 529 errormsg:"Please enter a valid email address" 530 }, { 531 ele : "input.form-input-name", 532 datatype : "*1-200", 533 nullmsg:"Please enter a valid user name",
534 errormsg:"Please enter a valid user name" 535 } 536 ]) 537}) 538 539function tabContainer(container,title,panel){ 540 $(container).each(function(){ 541 $(this).find(title).each(function(){ 542 if($(this).hasClass('current')){ 543 j=$(this).index(); 544 $(this).parents(container).find(panel).eq(j).removeClass('disabled') 545 } 546 $(this).click(function(){ 547 i=$(this).index(); 548 $(this).addClass('current').siblings().removeClass('current'); 549 $(this).parents(container).find(panel).eq(i).show(); 550 $(this).parents(container).find(panel).not($(this).parents(container).find(panel).eq(i)).hide(); 551 }) 552 }) 553 }) 554 555 } 556 557function mobileTabContainer(container,title,panel,titleSpan,panelContent){ 558 $(container).each(function(){ 559 if($(this).find(title).length>0 && $(this).find(panel).length>0){ 560 $(this).append('<div class="mobile-tab-items"></div>') 561 var mobileTabItem='<div class="mobile-tab-item"><h2 class="mobile-tab-title"></h2><div class="mobile-tab-panel"></div></div>' 562 $(this).find(title).each(function(){ 563 $(this).parents(container).find('.mobile-tab-items').append(mobileTabItem) 564 }) 565 } 566 var mobileTabTitle=$(this).find('.mobile-tab-items .mobile-tab-title') 567 var mobileTabPanel=$(this).find('.mobile-tab-items .mobile-tab-panel') 568 for(var i=0;i<$(this).find(title).length;i++){ 569 $(this).find(title).eq(i).find(titleSpan).clone().appendTo(mobileTabTitle.eq(i)) 570 $(this).find(panel).eq(i).find(panelContent).clone().appendTo(mobileTabPanel.eq(i)) 571 } 572 }) 573 574 } 575function picturesShow(container,picturesItem,length){ 576 var containerWidth=$(container).width() 577 var itemCurrentWidth=((1-1/8*(length-1))*100)+"%" 578 var itemWidth=(1/8*100)+"%" 579 $(container).find(picturesItem).css('width',itemWidth) 580 $(container).find(picturesItem).eq(0).addClass('current').css('width',itemCurrentWidth) 581 $(container).find(picturesItem).find('.item-wrap').css('width',containerWidth*(1-1/8*(length-1)) ) 582 $(container).find(picturesItem).each(function(){ 583 $(this).click(function(){ 584 $(this).addClass('current').stop().animate({'width':itemCurrentWidth},600) 585 $(this).siblings().removeClass('current').stop().animate({'width':itemWidth},300) 586 587 }) 588 }) 589 } 590 591 592$(function(){ 593if (!(/msie [6|7|8|9]/i.test(navigator.userAgent))){ 594 var wow = new WOW({ 595 boxClass: 'wow', 596 animateClass: 'animated', 597 offset: 0, 598 mobile: false, 599 live: true 600 }); 601 wow.init(); 602}; 603}) 604 605 606function decrease(item,time){ 607 var i=0; 608 var j=item.length; 609 item.each(function(){ 610 i++ 611 j-- 612 var ii=(i-1) 613 var jj=time*j 614 item.eq(ii).attr('data-wow-delay',jj+'s') 615 }) 616 } 617function add(item,time){ 618 item.each(function(index){ 619 $(this).attr('data-wow-delay',(index*time)+'s') 620 }) 621 } 622$(function(){ 623 add( $('.company-synopses .synopsis-item'),.2) 624 add($('.offer-items .offer-item'), .2) 625 add($('.foot-item .foot-cont li'),.3) 626 add($('.foot-items .foot-item'),.2) 627 decrease( $('.news-items .news-item'),.1) 628 containerItems('.product-items',2,'.items-content','.product-item',4,3,2,1) 629 }) 630 631function containerItems(container,itemDisplayLength,containerName,cItem,showItems,showItems01,showItems02,showItems03){ 632 $(container).each(function(){ 633 $(this).find(containerName).hide() 634 var itemLength=$(this).find(containerName).find(cItem).size() 635 if($(this).find('.product-container').length<1){ 636 $(this).append("<div class='product-container'></div>") 637 } 638 for(var i=0;i<(itemLength/itemDisplayLength);i++){ 639 640 $(this).find('.product-container').append("<div class='product-slide-item'></div>") 641 } 642 $(this).find('.product-container').find('.product-slide-item').each(function(){ 643 var itemContIndex=parseInt($(this).index()) 644 if(itemContIndex>0){ 645 var itemIndex=itemContIndex*itemDisplayLength; 646 var current=$(this).parents('.product-container').find('.product-slide-item').eq(itemContIndex); 647 for(var i=0;i<itemDisplayLength;i++){ 648 var move=$(this).parents(container).find(containerName).find(cItem).eq(itemIndex+i); 649 move.clone().appendTo(current); 650 } 651 } 652 else{ 653 for(var i=0;i<itemDisplayLength;i++){ 654 var move=$(this).parents(container).find(containerName).find(cItem).eq(i); 655 move.clone().appendTo($(this).parents('.product-container').find('.product-slide-item').eq(0)); 656 657 } 658 } 659 660 })
661var productContainer=$(this).find('.product-container') 662 productContainer.owlCarousel({ 663 loop:true, 664 margin:0, 665 dots: true, 666 smartSpeed:180, 667 lazyLoad:true, 668 dots: true, 669 nav:true, 670 mouseDrag:true, 671 items:4, 672 slideBy:4, 673 responsive: { 674 0: { 675 items:showItems03, 676 slideBy:showItems03 677 678 }, 679 320: { 680 items:showItems02, 681 slideBy:showItems02 682 683 684 }, 685 500: { 686 items:showItems01, 687 slideBy:showItems01 688 689 }, 690 691 768: { 692 items:showItems, 693 slideBy:showItems 694 } 695 } 696 }) 697 698}) 699 700} 701 702 703 704 $(function(){ 705 $('.synopsis-item').each(function(){ 706 $('.synopsis-item').eq(1).addClass('current') 707 $(this).hover(function(){ 708 $(this).addClass('current').siblings().removeClass('current') 709 }) 710 }) 711 712}) 713 714 715 716$(function(){ 717 $('.faq-item').each(function(index){ 718 var _this=$(this) 719 var title=_this.find('.faq-title') 720 var cont=_this.find('.faq-cont') 721 if(index==0){ 722 title.addClass('show-title') 723 } 724 title.on('click',function(){ 725 if(cont.is(':hidden') && !$(this).hasClass('show-title')){ 726 cont.slideDown('fast') 727 $(this).addClass('show-title') 728 _this.siblings().find('.faq-title').removeClass('show-title') 729 _this.siblings().find('.faq-cont').slideUp('fast') 730 } 731 else{ 732 cont.slideUp('fast') 733 $(this).removeClass('show-title') 734 } 735 }) 736 }) 737 }) 738 739 740/*language*/ 741function changeuRL(link){ 742 var curUrl=document.location.href; 743 var oldUrl=window.location.host+'/'; 744 var lgArr=['fr/','de/','pt/','es/','ru/','ko/','ar/','ga/','ja/','el/','tr/','it/','da/','ro/','id/','cs/','af/','sv/','pl/','eu/','ca/','eo/','hi/','lo/','sq/','am/','hy/','az/','be/','bn/','bs/','bg/','ceb/','ny/','co/','hr/','nl/','et/','tl/','fi/','fy/','gl/','ka/','gu/','ht/','ha/','haw/','iw/','hmn/','hu/','is/','ig/','jw/','kn/','kk/','km/','ku/','ky/','la/','lv/','lt/','lb/','mk/','mg/','ms/','ml/','mt/','mi/','mr/','mn/','my/','ne/','no/','ps/','fa/','pa/','sr/','st/','si/','sk/','sl/','so/','sm/','gd/','sn/','sd/','su/','sw/','tg/','ta/','te/','th/','uk/','ur/','uz/','vi/','cy/','xh/','yi/','yo/','zu/','zh-CN/','zh-TW/','zh/']; 745 746 747 $.each(lgArr,function(i,lenItem){ 748 var lgUrl=oldUrl.toString()+lenItem; 749 if(curUrl.indexOf(lgUrl)!=-1){ 750 link.each(function(i){ 751 if(!$(this).parents().hasClass('language-flag')){ 752 var iLink; 753 if($(this).prop('href')){ 754 iLink=$(this).prop('href'); 755 } 756 if(String(iLink).indexOf(oldUrl)!=-1 && String(iLink).indexOf(lgUrl)==-1 && curUrl.indexOf(lgUrl)!=-1){ 757 var newLink=iLink.replace(oldUrl,lgUrl); 758 $(this).attr('href',newLink); 759 } 760 } 761 }) 762 } 763 }); 764} 765$(function(){ 766 changeuRL($('a')); 767}) 768 769 $(document).ready(function(){ 770 771 $('.prisna-wp-translate-seo').contents().filter(function() { 772 773 return this.nodeType === 3; 774 775 }).remove(); 776 777 $('.change-language .change-language-cont').append("<div class='change-empty'>Untranslated</div>") 778 779 $('.prisna-wp-translate-seo').append("<div class='lang-more'>More Language</div>") 780 781 if($('body .prisna-wp-translate-seo').length>0 && $('.change-language .prisna-wp-translate-seo').length<1){ 782 783 $('.prisna-wp-translate-seo').appendTo('.change-language-cont') 784 785 if($('.change-language .change-language-cont .prisna-wp-translate-seo li').length>0){ 786 787 $('.change-language .change-language-cont .change-empty').hide() 788 789 $('.change-language .change-language-cont .prisna-wp-translate-seo li').each(function(index){ 790 791 if(index>14 ){ 792 793 $(this).addClass('lang-item lang-item-hide') 794 $('.change-language-cont').find('.lang-more').show() 795 796 }else{ 797 $('.change-language-cont').find('.lang-more').hide() 798 } 799 }) 800 801 if($('.change-language-cont .lang-more').length>0){ 802 803 $('.change-language-cont .lang-more').click(function(){ 804 805 if($(this).parents('.change-language-cont').find('.prisna-wp-translate-seo li.lang-item').hasClass('lang-item-hide')){ 806 $(this).parents('.change-language-cont').find('.prisna-wp-translate-seo li.lang-item').removeClass('lang-item-hide') 807 808 $(this).text('x') 809 }else{ 810 $(this).parents('.change-language-cont').find('.prisna-wp-translate-seo li.lang-item').addClass('lang-item-hide') 811 $(this).text('More Language') 812 } 813 }) 814 } 815 }else{ 816 $('.change-language .change-language-cont .change-empty').fadeIn() 817 } 818 } 819 var mouseover_tid = []; 820 821var mouseout_tid = []; 822 823 $('.change-language').each(function(index){ 824 825 $(this).hover( 826 function(){ 827 var _self = this; 828 clearTimeout(mouseout_tid[index]); 829 mouseover_tid[index] = setTimeout(function() { 830 $(_self).find('.sub-content').slideDown(); 831 $('.change-language-info .change-language-title').addClass('title-show').removeClass('title-hide'); 832 }, 150); 833 }, 834 function(){ 835 var _self = this; 836 clearTimeout(mouseover_tid[index]); 837 mouseout_tid[index] = setTimeout(function() { 838 $(_self).find('.sub-content').slideUp(); 839 $('.change-language-info .change-language-title').addClass('title-hide').removeClass('title-show'); 840 }, 50); 841 } 842 ); 843 }) 844 }) 845$(function(){ 846 847$('body .inquiry-form-wrap.ct-inquiry-form').append('<div class="ad_prompt">Write your message here and send it to us</div>') 848 849 if($('body .inquiry-form-wrap.ct-inquiry-form').length>0 && $('.scrollsidebar#scrollsidebar .side_list .email').length>0){ 850 851 var webTop=$('body .inquiry-form-wrap.ct-inquiry-form').offset().top-50 852 853 $('.scrollsidebar#scrollsidebar .side_list .email').after('<a class="ad_email" href="javascript:">'+ $('.scrollsidebar#scrollsidebar .side_list .email').text()+'</a>') 854 855 $('.scrollsidebar#scrollsidebar .side_list .email').css('display','none') 856 857 $('.scrollsidebar#scrollsidebar .side_list .ad_email').click(function(){ 858 $("html, body").animate({ scrollTop:webTop }, 1000); 859 860 $(".ad_prompt").show().delay(3000).hide(300);
861 862 }) 863 } 864 }) 865 866$(function(){ 867 868 if($('body .inquiry-form-wrap.ct-inquiry-form').length>0 && $('.email.inquiryfoot').length>0){ 869 var webTop=$('body .inquiry-form-wrap.ct-inquiry-form').offset().top-50 870 $('.email.inquiryfoot').before('<a class="email inquiryfoot ad_inquiryfoot" href="javascript:">'+ $('.email.inquiryfoot').text()+'</a>') 871 $('.email.inquiryfoot.ad_inquiryfoot').click(function(){ 872 $("html, body").animate({ scrollTop:webTop }, 1000); 873 874 $(".ad_prompt").show().delay(3000).hide(300); 875 }) 876 } 877 }) 878$(function(){ 879 if($('body .inquiry-form-wrap.ct-inquiry-form').length>0 && $('.product-btn-wrap .email').length>0){ 880 var webTop=$('body .inquiry-form-wrap.ct-inquiry-form').offset().top-50 881 $('.product-btn-wrap .email').before('<a class="email page_pd_email" href="javascript:">'+ $('.product-btn-wrap .email').text()+'</a>') 882 $('.product-btn-wrap .email.page_pd_email').click(function(){ 883 $("html, body").animate({ scrollTop:webTop }, 1000); 884 $(".ad_prompt").show().delay(3000).hide(300); 885 }) 886 } 887 }); 888/* CALL PLACEHOLDER */ 889 890 setREVStartSize(); 891 892 var tpj=jQuery; 893 894 /*tpj.noConflict();*/ 895 896 var revapi3; 897 898 tpj(document).ready(function() { 899 900 if(tpj('#rev_slider_3_1').revolution == undefined){ 901 902 revslider_showDoubleJqueryError('#rev_slider_3_1'); 903 904 }else{ 905 906 revapi3 = tpj('#rev_slider_3_1').show().revolution({ 907 908 dottedOverlay:"none", 909 910 delay:9000, 911 912 startwidth:1920, 913 914 startheight:700, 915 916 }); 917 918 } 919 920 }); 921$(function() { 922 $("#scrollsidebar").fix({ 923 float : 'right', 924 durationTime : 400 925 }); 926 $('input[name=refer]').val(window.location.href); 927 928 }); 929 930// new add 931 932/*search*/ 933document.documentElement.className = 'js';; 934(function (window) { 935 if (document.querySelector('.web-search')) { 936 'use strict'; 937 var mainContainer = document.querySelector('.container'), 938 searchContainer = document.querySelector('.web-search'), 939 openCtrl = document.getElementById('btn-search'), 940 closeCtrl = document.getElementById('btn-search-close'), 941 inputSearch = searchContainer.querySelector('.search-ipt'); 942 943 function init() { 944 initEvents() 945 } 946 947 function initEvents() { 948 openCtrl.addEventListener('click', function () { 949 if (!searchContainer.classList.contains("search--open")) { 950 openSearch(); 951 } else { 952 closeSearch(); 953 } 954 }); 955 closeCtrl.addEventListener('click', closeSearch); 956 document.addEventListener('keyup', function (ev) { 957 if (ev.keyCode == 27) { 958 closeSearch() 959 } 960 }) 961 } 962 963 function openSearch() { 964 mainContainer.classList.add('main-wrap--move'); 965 searchContainer.classList.add('search--open'); 966 setTimeout(function () { 967 inputSearch.focus() 968 }, 600) 969 } 970 971 function closeSearch() { 972 mainContainer.classList.remove('main-wrap--move'); 973 searchContainer.classList.remove('search--open'); 974 inputSearch.blur(); 975 inputSearch.value = '' 976 } 977 init() 978 } 979})(window); 980 981// partner slides 982// ============================ 983$(function(){ 984 $('.partner-slides').owlCarousel({ 985 autoplay:false, 986 loop:true, 987 margin:30, 988 dots: true, 989 autoplayTimeout:30000, 990 smartSpeed:300, 991 lazyLoad:true, 992 dots: false, 993 nav: true, 994 responsive: { 995 0: { 996 items:1, 997 margin:0 998 }, 999 551: { 1000 items:2, 1001 slideBy:1, 1002 margin:10 1003 }, 1004 768: { 1005 items:4, 1006 slideBy:1, 1007 margin:15 1008 }, 1009 1280: { 1010 items:6, 1011 slideBy:1, 1012 margin:35, 1013 dots: false, 1014 nav: true 1015 } 1016 } 1017 }); 1018 $('.news-items').owlCarousel({ 1019 loop: true, 1020 margin: 0, 1021 dots: true, 1022 smartSpeed: 180, 1023 lazyLoad: true, 1024 dots: true, 1025 nav: true, 1026 mouseDrag: true, 1027 items: 1, 1028 slideBy: 1 1029 }) 1030}) 1031 1032
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.