我正在使用响应式滑块,它不会在悬停时停止,我不明白为什么,这是我的脚本告诉它在悬停时暂停
<script type='text/javascript'>
$(function () {
$(".rslides").responsiveSlides({
timeout: 8000,
pause: true,
});
});
</script>
这是实现它的页面的现场演示http://bloghutsbeta.blogspot.com/2012/04/testing-slider.html
相关标记:
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script src='http://files.cryoffalcon.com/javascript/responsiveslides.min.js' type='text/javascript'/>
HTML:
<ul class="rslides">
<li><img width="660" height="400" src="http://responsive-slides.viljamis.com/1.jpg" alt="" /></li>
<li><img width="660" height="400" src="http://responsive-slides.viljamis.com/2.jpg" alt="" /></li>
<li><img width="660" height="400" src="http://responsive-slides.viljamis.com/3.jpg" alt="" /></li>
</ul>
CSS:
.rslides {
position: relative;
list-style: none;
overflow: hidden;
width: 660px;
padding: 0;
margin: 0;
height:400px;
}
.rslides li {
position: absolute;
width: 660px;
height:400px;
left: 0;
top: 0;
}
.rslides li:first-child {
position: relative;
display: block;
float: left;
}
.rslides img {
display: block;
height: auto;
float: left;
width: 660px;
height:400px;
border: 0;
}
编辑:链接到这个插件的创建者的页面http://responsive-slides.viljamis.com/