前端-SuperSlide自动分页控制、自适应轮播图
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>SuperSlide自动分页控制</title>
<link rel="stylesheet" href="css/reset.css">
<style> /* 本案例CSS样式 */
#banner .slideBox{ width:100%; height:auto; overflow:hidden; position:relative; }
#banner .slideBox .hd{ width: 100%;height:15px; overflow:hidden; position:absolute; right:0px; bottom:5px; z-index:1; }
#banner .slideBox .hd ul{ overflow:hidden; zoom:1; display: table;margin: 0 auto; }
#banner .slideBox .hd ul li{float:left;margin-right:2px;width:60px;height:4px;line-height:14px;text-align:center;background:#fff;cursor:pointer;opacity:0.5;}
#banner .slideBox .hd ul li.on{opacity:1}
#banner .slideBox .bd{ position:relative; height:100%; z-index:0; }
#banner .slideBox .bd li{ zoom:1; vertical-align:middle; }
#banner .slideBox .bd img{ width:100%; height:auto; display:block; }
/* 下面是前/后按钮代码,如果不需要删除即可 */
#banner .slideBox .prev,
#banner .slideBox .next{ position:absolute; left:3%; top:50%; margin-top:-25px; display:block; width:32px; height:40px; filter:alpha(opacity=50);opacity:0.5; }
#banner .slideBox .next{ left:auto; right:3%; background-position:8px 5px; }
#banner .slideBox .prev:hover,
#banner .slideBox .next:hover{ filter:alpha(opacity=100);opacity:1; }
#banner .slideBox .prevStop{ display:none; }
#banner .slideBox .nextStop{ display:none; }
</style>
</head>
<body>
<!-- banner -->
<!-- banner -->
<div id="banner">
<div id="slideBox" class="slideBox">
<div class="hd">
<ul></ul>
</div>
<div class="bd">
<ul>
<li><img src="img/1.jpg" alt=""></li>
<li><img src="img/2.jpg" alt=""></li>
<li><img src="img/3.jpg" alt=""></li>
<li><img src="img/4.jpg" alt=""></li>
</ul>
</div>
<!-- 下面是前/后按钮代码,如果不需要删除即可 -->
<a class="prev" href="javascript:void(0)"> <img src="img/left.png" alt="上一页"></a>
<a class="next" href="javascript:void(0)"> <img src="img/right.png" alt="下一页"></a>
</div>
</div>
<script src="js/jquery1.42.min.js"></script>
<script src="js/jquery.SuperSlide.2.1.3.js"></script>
<script>
// #banner轮播图控制
$("#banner > .slideBox").slide({ titCell:".hd ul",mainCell: ".bd ul",effect: "leftLoop", autoPlay: true, scroll: 1, vis: "auto",interTime:5000,autoPage:'<li></li>' });
</script>
<!-- banner END-->
</body>
</html>
前端-SuperSlide自动分页控制、自适应轮播图的更多相关文章
- JavaScript 自适应轮播图
代码 话不多说,先上代码,方便复制粘贴.演示 <!DOCTYPE html> <html lang="en"> <head> <meta ...
- Web前端原生JavaScript浅谈轮播图
1.一直来说轮播图都是困扰刚进业内小白的一大难点,因为我们不仅需要自己作出一个比较完美的运动框架(虽然网上一抓一大把,但是哪有比自己做出来实现的有成就感,不是吗?^_^),还必须需要非常关键性的把握住 ...
- 学习笔记: js插件 —— SuperSlide 2 (轮播图插件,PC用)
SuperSlide 2 轮播图插件,较老.但还好用. 适用于PC,是绑定到jquery上的方法: $.slide(); 如果在实际中找不到.slide方法,请检查jquery等.js文件的引入次序 ...
- bootstrap轮播图组件
一.轮播图组件模板(官方文档) <div id="carousel-example-generic" class="carousel slide" dat ...
- 自己动手丰衣足食之轮播图一动态修改marginTop属性实现轮播图
引言 学习jQuery有年头了,刚开始学习时自己动手写过轮播图,放的久了以至于忘了大致思路了.现在转而做前端,抽空把jquery轮播图拿出来写一写,把各种思路都自己练习练习,这里主要使用动态修改mar ...
- 第124天:移动web端-Bootstrap轮播图插件使用
Bootstrap JS插件使用 > 对于Bootstrap的JS插件,我们只需要将文档实例中的代码粘到我们自己的代码中> 然后作出相应的样式调整 Bootstrap中轮播图插件叫作Car ...
- Bootstrap中轮播图
Bootstrap中轮播图插件叫作Carousel,为了清晰的表明每个标签在这里是什么意思,我把解释写在了下面的代码中. <!-- 以下容器就是整个轮播图组件的整体, 注意该盒子必须加上 cla ...
- 从零开始学习前端JAVASCRIPT — 11、JavaScript运动模型及轮播图效果、放大镜效果、自适应瀑布流
未完待续...... 一.运动原理 通过连续不断的改变物体的位置,而发生移动变化. 使用setInterval实现. 匀速运动:速度值一直保持不变. 多物体同时运动:将定时器绑设置为对象的一个属性. ...
- iview Carousel 轮播图自适应宽高;iview 轮播图 图片重叠问题;iview tabs 高度互相影响问题;vue this问题;
最终效果图: 一.轮播图中图片自适应宽高: <Carousel loop v-bind:height="imgHeight+'px'" v-model="caro ...
随机推荐
- 图论 List
题目 #A 小 K 的农场 (Unaccepted) #B 信息传递 (Unaccepted) #C 最短路计数 (Accepted) #D 通往奥格瑞玛的道路 (Accepted) ...
- CSS3订单提交按钮Loading代码
<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"& ...
- centos7systemctl介绍
Linux中如何启动.重启.停止.重载服务以及检查服务(如 httpd.service)状态 # systemctl start httpd.service # systemctl restart ...
- 【Pytest】python单元测试框架pytest简介
1.Pytest介绍 pytest是python的一种单元测试框架,与python自带的unittest测试框架类似,但是比unittest框架使用起来更简洁,效率更高.根据pytest的官方网站介绍 ...
- php面向对象三大特性
1.封装: 目的:使类更加安全 步骤:1.成员变量变成private(私有的)2.设置方法/调用方法3.在方法中增加限制 <?php class shao { private $aa;//必须是 ...
- Linux_Bash常用脚本
目录 目录 从用户列表中过滤用户名并创建用户 awktrcut 指令的文本处理 tr指令 cut指令 awk指令 备份文件 测试LFTPServer权限设定 开启Httpd 安装Httpd 批量创建用 ...
- vue封装分页组件
element提供的分页是已经封装好的组件,在这里再次封装是为了避免每个用到分页的页面点击跳转时都要写一遍跳转请求 分页组件 <!--分页组件--> <template> &l ...
- Vue过渡:用Velocity实现JavaScript钩子
Velocity is an animation engine with a similar API to jQuery's $.animate(). It has no dependencies, ...
- Locally weighted regression algorithm
在此引出另一种模型:Locally weighted regression algorithm(LWLR/LWR),通过名字我们可以推断,这是一种更加关注局部变化的模型.的确如此,在普通的linear ...
- Item-Based Collaborative Recommender System
与User-Based Collaborative Recommender System认为‘类似的用户会对同一个item给出类似的打分’不同,Item-Based Collaborative Rec ...