jquery优酷TV轮播图源码免费分享
jquery优酷TV轮播图源码免费分享效果图:

jquery优酷TV轮播图源码免费分享
jquery优酷TV轮播图源码免费分享
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 | <!DOCTYPE HTML> <html> <head> <title>jquery优酷TV轮播图源码免费分享</title> <meta charset="utf-8"> <meta name="Author" content=""> <style type='text/css'> *{ margin:0; padding:0;} #wrap{ width:970px; height:300px; margin:50px auto; position:relative; overflow:hidden; } #pic{ width:970px; height:270px; position:relative; } #pic li{ list-style:none; width:0; height:0; position:absolute; top:135px; left:485px; opacity:0; filter:alpha(opacity=0); } #pic li span{ width:100%; height:100%; position:absolute; top:0; left:0; filter:alpha(opacity=50); background:rgba(0,0,0,.5); display:block; } #pic li img{ width:100%; height:100%; } #pic li.l1{ width:640px; height:270px; left:165px; top:0px; z-index:10;opacity:1; filter:alpha(opacity=100);} #pic li.l2{ width:530px; height:220px; left:440px; top:25px; z-index:9;opacity:1; filter:alpha(opacity=100);} #pic li.l0{ width:530px; height:220px; left:0px; top:25px; z-index:9;opacity:1; filter:alpha(opacity=100);} #pic li.l3{ width:300px; height:150px; left:970px; top:60px; z-index:8;} #pic li.l9{ width:300px; height:150px; left:-300px; top:60px; z-index:8;} #btn div{ width:45px; height:45px; position:absolute; top:50%; margin-top:-22px; z-index:999; cursor:pointer; } #left{ background:url(img/left.png); left:0; } #right{ background:url(img/right.png); right:0; } #tab{ width:200px; height:10px; padding:10px 0; position:absolute; left:50%; margin-left:-100px; bottom:0; } #tab li{ list-style:none; float:left; width:10px; height:10px; margin:0 5px; border-radius:100%; background:#bbb; cursor:pointer; } #tab li.on{ background:#0cf; } </style> </head> <body> <div id="wrap"> <div id='pic'> <li class='l1'><img src="img/1.jpg" alt="" /></li> <li class='l2'><img src="img/2.jpg" alt="" /></li> <li class='l3'><img src="img/3.jpg" alt="" /></li> <li><img src="img/4.jpg" alt="" /></li> <li><img src="img/5.jpg" alt="" /></li> <li><img src="img/6.jpg" alt="" /></li> <li><img src="img/7.jpg" alt="" /></li> <li><img src="img/8.jpg" alt="" /></li> <li class='l9'><img src="img/9.jpg" alt="" /></li> <li class='l0'><img src="img/10.jpg" alt="" /></li> </div> <div id="btn"> <div id="left"></div> <div id="right"></div> </div> <div id="tab"> <li class='on'></li> <li></li> <li></li> <li></li> <li></li> <li></li> <li></li> <li></li> <li></li> <li></li> </div> </div> <script type="text/javascript" src='js/jquery-1.12.1.min.js'></script> <script type="text/javascript"> (function(){ var $left = $('#left'); var $right = $('#right'); var $li = $('#pic li'); var $tabLi = $('#tab li'); var index = 0; $li.append('<span></span>'); $('#pic li span').eq(0).css('display' , 'none'); var arrW=[],arrH=[],arrL=[],arrT=[],arrZ=[],arrS=[],arrO=[]; var nowTime = 0; $right.click(function(){ if ( new Date() - nowTime > 500 ) { nowTime = new Date(); index ++; index %= $li.length; $tabLi.eq(index).addClass('on').siblings().removeClass('on'); fn( $(this).index() ); } }); $left.click(function(){ if ( new Date() - nowTime > 500 ) { nowTime = new Date(); index --; if(index<0)index=$li.length-1; $tabLi.eq(index).addClass('on').siblings().removeClass('on'); fn( $(this).index() ); } }); $tabLi.click(function(){ $(this).addClass('on').siblings().removeClass('on'); var nowIndex = $(this).index(); var x = nowIndex - index; if ( x == 1 || x == -($li.length-1) ) { fn( true ); index = nowIndex; } else if ( x == -1 || x == $li.length-1 ) { fn( false ); index = nowIndex; } else if ( nowIndex != index ) { $li.each(function(i){ arrW[i] = $(this).css('width'); arrH[i] = $(this).css('height'); arrL[i] = $(this).css('left'); arrT[i] = $(this).css('top'); arrZ[i] = $(this).css('zIndex'); arrS[i] = $(this).find('span').css('display'); arrO[i] = $(this).css('opacity'); }); $li.each(function(i){ $(this).animate({ width : 0, height : 0, opacity : 0, left : '485px', top : '135px' },300); }); setTimeout(function(){ $li.each(function(i){ var a = i - (nowIndex - index); if(a<0)a+=$li.length; if(a>=$li.length)a-=10; $(this).find('span').css('display' , arrS[a]); $(this).css('zIndex' , arrZ[a]).animate({ width : arrW[a], height : arrH[a], left : arrL[a], top : arrT[a], opacity : arrO[a] },500); }); index = nowIndex; },300); } }); function fn( x ){ $li.each(function(i){ arrW[i] = $(this).css('width'); arrH[i] = $(this).css('height'); arrL[i] = $(this).css('left'); arrT[i] = $(this).css('top'); arrZ[i] = $(this).css('zIndex'); arrS[i] = $(this).find('span').css('display'); arrO[i] = $(this).css('opacity'); }); $li.each(function(i){ if ( x ) { var a = i-1; if(a<0)a=$li.length-1; } else { var a = i+1; if(a==$li.length)a=0; } $(this).find('span').css('display' , arrS[a]); $(this).css('zIndex' , arrZ[a]).animate({ width : arrW[a], height : arrH[a], left : arrL[a], top : arrT[a], opacity : arrO[a] },500); }); } })(); </script> </body> </html> |
最新评论
真的是简单的英语。
网址收藏了,学习了
特效不错,博主发文章很用心
这篇讲seo的文章很有用,非常不错
学习了,感谢
jquery中捕获文本,啧啧,相当不错
这个表情包不错,可以用来制作论坛评论框上面的表情图
一款不错的tab切换界面,不错不错
这个wordpress主题看上去还是不错的
这个站点特效还是蛮多的,值得推荐
最近在看jquery,做一个二级栏目出来,搜到了这个站点,非常不错,还提供源代码的下载,大赞
期待博主整理更多地关于wordpress主题出来
一款不错的wordpress主题,值得推荐
有意思有意思
规范已收藏
到此一游
不错,点赞
这个主题是我见过的比较不错的主题,不像一些主题封装的特别紧密,没法改动一些细节,Smile_Blog主题自定义程度高,很适合新手入手学习wordpress,且还在不断地更新新功能,不错
刚学习做网站不久,文章不错,学习了
已下载,看着界面非常不错的