如何使自动播放的革命滑块在HTML网站
How to enable autoplay of revolution slider in HTML website
这里是Javascript被用于相同的,但滑块不是自动播放模式。代码,我使用的革命滑块如下所示。滑块工作,但只点击…它不能在自动播放模式下工作
/* ========================================================== */
/* Revolution Slider - Home Page */
/* ========================================================== */
var tpj = jQuery;
var revapi202;
tpj(document).ready(function() {
if (tpj("#rev_slider_202_1").revolution == undefined) {
revslider_showDoubleJqueryError("#rev_slider_202_1");
} else {
revapi202 = tpj("#rev_slider_202_1").show().revolution({
sliderType: "carousel",
jsFileLocation: "../../revolution/js/",
sliderLayout: "fullscreen",
dottedOverlay: "none",
delay: 1000,
navigation: {
keyboardNavigation: "off",
keyboard_direction: "horizontal",
mouseScrollNavigation: "off",
onHoverStop: "off",
touch: {
touchenabled: "on",
swipe_threshold: 75,
swipe_min_touches: 50,
swipe_direction: "horizontal",
drag_block_vertical: false
},
bullets: {
enable: true,
hide_onmobile: true,
hide_under: 800,
style: "zeus",
hide_onleave: false,
direction: "horizontal",
h_align: "center",
v_align: "bottom",
h_offset: 0,
v_offset: 30,
space: 5,
tmp: '<span class="tp-bullet-image"></span><span class="tp-bullet-imageoverlay"></span><span class="tp-bullet-title">{{title}}</span>'
}
},
carousel: {
horizontal_align: "center",
vertical_align: "center",
fadeout: "off",
maxVisibleItems: 3,
infinity: "on",
space: 0,
stretch: "off"
},
responsiveLevels: [1240, 1024, 778, 480],
visibilityLevels: [1240, 1024, 778, 480],
gridwidth: [1240, 1024, 778, 480],
gridheight: [868, 768, 960, 720],
lazyType: "none",
shadow: 0,
spinner: "off",
stopLoop: "on",
stopAfterLoops: 0,
stopAtSlide: 0,
shuffle: "off",
autoHeight: "off",
minHeight:600,
fullScreenAutoWidth: "off",
fullScreenAlignForce: "off",
fullScreenOffsetContainer: "",
fullScreenOffset: "60px",
disableProgressBar: "on",
hideThumbsOnMobile: "off",
hideSliderAtLimit: 0,
hideCaptionAtLimit: 0,
hideAllCaptionAtLilmit: 0,
debugMode: false,
fallbacks: {
simplifyAll: "off",
nextSlideOnWindowFocus: "off",
disableFocusListener: false,
}
});
}
}); /*ready*/
根据这里的文档:https://www.themepunch.com/revsliderjquery-doc/additional-javascript-settings/#autoplay-randomize
您需要将设置更改为:
stopLoop: "off",
stopAfterLoops: -1,
stopAtSlide: -1
应该设置为自动旋转幻灯片。
相关文章:
- 如何重定向到我的html网站youtube嵌入视频打开在youtube应用程序
- 我制作html网站的一小部分——我有一个javascript部分
- HTML网站无法在选项卡之间切换
- HTML网站中的数据库连接方式,应该在chrome和Firefox中支持
- 通过 TCP 从 html 网站发送 JSON 包
- 带有 html 网站中 SQL 数据的范围选择器的高图表
- 如何将PHP脚本插入WordPress和HTML网站
- 如何使用 onload 事件从 HTML 网站在 Windows 2008 上的文件共享上运行批处理文件
- 我怎样才能使图像出现在 html 网站正文中的 facebook 链接中
- 加载 HTML 网站时,安卓上的窗口高度错误
- 将Microsoft的情感 API 添加到 HTML 网站
- 在bootstrap html网站上进行客户集成
- 如何在HTML网站中显示HTML源代码
- 使用video.js在html网站中包含一个MJPEG
- Flexslider无法在html网站中工作(jQuery无法加载?)
- 如何在博客或其他html网站中创建类似的锁定
- JavaScript/HTML网站:检测选择选项中选择的选项
- 我的html网站不显示在移动设备
- 我如何要求我的Safari浏览器用户使用谷歌浏览器为我的HTML网站
- HTML网站完全全屏类似于flash全屏