jquery.flexslider.js带左右箭头且带按钮可滚动的图片插件

插件介绍

FlexSlider是一个非常出色的jQuery滑动切换插件,它支持所有主流浏览器,并有淡入淡出效果。FlexSlider对于网站开发者来说是一个不错测JQUERY特效,因为支持全浏览器深受中国网站前端开发者的喜爱!

插件下载

下载地址: http://pan.baidu.com/s/1jGDyjzC 


最简使用教程

JS和CSS引用代码:

<script src="js/jquery.min.js" type="text/javascript"></script>
<script type="text/javascript" src="js/jquery.flexslider-min.js"></script>
<link rel="stylesheet" type="text/css" href="css/flexslider.css" />
<script type="text/javascript">
	$(function() {
		$("#banner").flexslider({
			controlNav:false, //是否显示底部圆角按钮
			animation:'slide', //切换方式
			slideshowSpeed: 4000, //展示时间间隔ms
			animationSpeed: 400, //滚动时间ms
			touch: true //是否支持触屏滑动
		});
	});	
</script>

HTML代码:

<!-- banner -->
<div class="banner">
	<div class="flexslider" id="banner">
		<ul class="slides">
			<li style="background:url(images/banner.jpg) no-repeat center center;height:625px;"></li>
			<li style="background:url(images/banner2.jpg) no-repeat center center;height:625px;"></li>
			<li style="background:url(images/banner3.jpg) no-repeat center center;height:625px;"></li>
			<li style="background:url(images/banner4.jpg) no-repeat center center;height:625px;"></li>
		</ul>
	</div>
</div>
<!-- banner end -->

参数说明:

参数 描述 默认值
animation 动画效果类型,有”fade”:淡入淡出,”slide”:滑动 “fade”
easing 内容切换时缓动效果,需要jquery easing插件支持 “swing”
direction 内容滚动方向,有”horizontal”:水平方向 和”vertical”:垂直方向 “horizontal”
animationLoop 是否循环滚动 true
startAt 初始滑动时的起始位置,定位从第几个开始滑动 0
slideshow 是否自动滑动 true
slideshowSpeed 滑动内容展示时间(ms) 7000
animationSpeed 内容切换时间(ms) 600
initDelay 初始化时延时时间 0
pauseOnHover 鼠标滑向滚动内容时,是否暂停滚动 false
touch 是否支持触摸滑动 true
directionNav 是否显示左右方向箭头按钮 true
keyboard 是否支持键盘方向键操作 true
minItems 一次最少展示滑动内容的单元个数 1
maxItems 一次最多展示滑动内容的单元个数 0
move 一次滑动的单元个数 0
回调函数 start: function(){}, 
before: function(){},
after: function(){}, 
end: function(){}, 
added: function(){}, 
removed: function(){}, 
init: function(){},

原文链接: jquery.flexslider.js带左右箭头且带按钮可滚动的图片插件 版权所有,转载时请注明出处,违者必究。
注明出处格式:流年不会忘却 ( https://www.liunianer.com/post-23.html )

0则回应给“jquery.flexslider.js带左右箭头且带按钮可滚动的图片插件”