Html
    Css
    Js

    
                        
	* {
	padding:0;
	margin:0;
}
ul {
	list-style:none;
}
img {
	vertical-align:middle;
	border:none;
}
.wrap {
	width:790px;
	height:340px;
	margin:0px auto;
	position:relative;
}
.wrap .img li {
	position:absolute;
	left:0;
	top:0;
	display:none;
}
.wrap .num {
	position:absolute;
	left:0;
	bottom:20px;
	font-size:0;
	text-align:center;
	width:100%;
}
.wrap .num li {
	width:20px;
	height:20px;
	display:inline-block;
	background:#666;
	text-align:center;
	line-height:20px;
	color:#fff;
	border-radius:50%;
	font-size:16px;
	margin:0 3px;
	cursor:pointer;
}
.wrap .num li.active {
	background:#a00;
}
.wrap .btn {
	position:absolute;
	top:50%;
	margin-top:-30px;
	width:30px;
	height:60px;
	background:rgba(0,0,0,.3);
	color:#fff;
	text-align:center;
	line-height:60px;
	font-size:40px;
	display:none;
	cursor:pointer;
}
.wrap .btn-left {
	left:0;
}
.wrap .btn-right {
	right:0;
}
.wrap:hover .btn {
	display:block;
}

                        
↑上面代码改变,会自动显示代码结果 jQuery调用版本:1.11.3
 立即下载

用jquery写京东轮播图,没写插件

2
      浪里格朗0
      2017/6/5 11:20:06
      轮播宽度怎么改
          随遇而安0
          2017/6/7 16:00:13

          css里面不是有宽度吗,改成width:100%不就好了,这是基础唉

      回复