$(function() { var _SlideshowTransitions = [ { $Duration: 600, $Delay: 90, $Cols: 8, $Rows: 4, $FlyDirection: 5, $Formation: $JssorSlideshowFormations$.$FormationZigZag, $Assembly: 1028, $ChessMode: { $Column: 3, $Row: 12 }, $Easing: { $Left: $JssorEasing$.$EaseInCubic, $Top: $JssorEasing$.$EaseInCubic, $Opacity: $JssorEasing$.$EaseOutQuad }, $Opacity: 2 }, { $Duration:1000, $Delay:80, $Cols:8, $Rows:4, $Opacity:2 }, { $Duration:1200,y:2,$Rows:2,$Zoom:11, $SlideOut:true,$ChessMode:{$Row:15},$Easing:{$Top:$JssorEasing$.$EaseInExpo,$Zoom:$JssorEasing$.$EaseInExpo,$Opacity:$JssorEasing$.$EaseLinear},$Assembly:2049,$Opacity:2 } ]; var options = { $DragOrientation: 3, $AutoPlay: true, $SlideDuration: 1500, $AutoPlayInterval: 0, $SlideshowOptions: { //Options which specifies enable slideshow or not $Class: $JssorSlideshowRunner$, //Class to create instance of slideshow $Transitions: _SlideshowTransitions, //Transitions to play slide, see jssor slideshow transition builder $TransitionsOrder: 0, //The way to choose transition to play slide, 1 Sequence, 0 Random $ShowLink: 2, //0 After Slideshow, 2 Always $ContentMode: false //Whether to trait content as slide, otherwise trait an image as slide } }; var jssor_slider1 = new $JssorSlider$('slider1_container', options); //responsive code begin //you can remove responsive code if you don't want the slider scales //while window resizing function ScaleSlider() { var parentWidth = $('#slider1_container').parent().width(); if (parentWidth) { jssor_slider1.$ScaleWidth(parentWidth); } else window.setTimeout(ScaleSlider, 30); } //Scale slider after document ready ScaleSlider(); //Scale slider while window load/resize/orientationchange. $(window).bind("load", ScaleSlider); $(window).bind("resize", ScaleSlider); $(window).bind("orientationchange", ScaleSlider); //responsive code end });