我需要帮助创建一个js函数,当用户右键单击幻灯片/图片中的任意位置时,幻灯片将移动到下一个幻灯片。
我正在使用bxSlider。
这里是JSFiddle示例http://jsfiddle.net/Yq3RM/202/
$('.bxslider').bxSlider({
mode: 'fade',
auto: 'true',
minSlides: 5,
maxSlides: 5,
touchEnabled: 'true',
swipeThreshold: 50,
speed: 1000,
pause: 5000,
preventDefaultSwipeX: 'true',
preventDefaultSwipeY: 'true',
keyboardEnabled: 'true',
controls: false,
});

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
<ul class="bxslider">
<li>
<img src="http://bxslider.com/images/730_200/hill_trees.jpg" />
</li>
<li>
<img src="http://bxslider.com/images/730_200/me_trees.jpg" />
</li>
<li>
<img src="http://bxslider.com/images/730_200/houses.jpg" />
</li>
<li>
<img src="http://bxslider.com/images/730_200/tree_root.jpg" />
</li>
<li>
<img src="http://bxslider.com/images/730_200/hill_fence.jpg" />
</li>
<li>
<img src="http://bxslider.com/images/730_200/trees.jpg" />
</li>
</ul>
<link href="http://bxslider.com/lib/jquery.bxslider.css" rel="stylesheet" />
<script src="http://bxslider.com/lib/jquery.bxslider.js"></script>
&#13;