I am using jssor full width slider for my website:
I want to show the next slide when I click anywhere in the current slide image. How can I do this?
I am adding a sample code for it HTML:
jQuery(document).ready(function($) {
var options = {
$FillMode: 4,
$AutoPlay: 1,
$Idle: 3000,
$PauseOnHover: 1,
$ArrowKeyNavigation: false,
$SlideEasing: $JssorEasing$.$EaseOutQuint,
$SlideDuration: 800,
$MinDragOffsetToSlide: 20,
$SlideSpacing: 0,
$Cols: 1,
$Align: 0,
$UISearchMode: 1,
$PlayOrientation: 1,
$DragOrientation: 1,
$BulletNavigatorOptions: {
$Class: $JssorBulletNavigator$,
$ChanceToShow: 2,
$Steps: 1,
$Rows: 1,
$SpacingX: 8,
$SpacingY: 8,
$Orientation: 1
},
$ArrowNavigatorOptions: {
$Class: $JssorArrowNavigator$,
$ChanceToShow: 0,
$Steps: 1
}
};
$("#slider1_container").css("display", "block");
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 resizes
function ScaleSlider() {
var bodyWidth = document.body.clientWidth;
if (bodyWidth)
jssor_slider1.$ScaleWidth(Math.min(bodyWidth, 1920));
else
window.setTimeout(ScaleSlider, 30);
}
ScaleSlider();
<div u="slides" style="cursor: move; position: absolute; left: 0px; top: 0px; width: 1300px; height: 500px; overflow: hidden;">
<div>
<img u="image" src2="images/fun/fun.png" />
</div>
<div>
<img u="image" src2="images/fun/1.png" />
</div>
<div>
<img u="image" src2="images/fun/2.png" />
</div>
<div>
<img u="image" src2="images/fun/3.png" />
</div>
<div>
<img u="image" src2="images/fun/4.png" />
</div>
</div>
<div u="navigator" class="jssorb21" style="bottom: 26px; right: 6px;">
<!-- bullet navigator item prototype -->
<div u="prototype"></div>
</div>