我在bootstrap的旋转木马上遇到了很多问题:
HTML:
<div id="myCarousel" class="contributors-carousel carousel slide">
<div class="carousel-inner">
<div class="item">
<div class="container">
<div class="contributor">
<img class="img-circle" src="http://redacted/image.gif" />
</div>
</div>
</div>
<div class="item">
<div class="container">
<div class="contributor">
<img class="img-circle" src="http://redacted/image.gif" />
</div>
</div>
</div>
<div class="item">
<div class="container">
<div class="contributor">
<img class="img-circle" src="http://redacted/image.gif" />
</div>
</div>
</div>
</div>
<a class="carousel-control left" href="#myCarousel" data-slide="prev">‹</a>
<a class="carousel-control right" href="#myCarousel" data-slide="next">›</a>
</div>
jQuery的:
$('#myCarousel').carousel();
随意尝试一下:
[删除]
答案 0 :(得分:1)
在您的代码中修复3件事
myCarousel
,否则您必须更改选择器active
上的item
个)contributors-carousel
以下是修复了您的代码的bootply:http://bootply.com/69067