bootstrap輪播點不動
頁面中用了2個輪播後,輪播點不動了?
解決辦法如下:
如果複製的框架的程式碼過來,你頁面中需要做2個輪播,你就會改掉原有的輪播id,那麼記得將我紅色部分都改成一致的。
PC端輪播
<div class="container-fluid container-clear hidden-xs hidden-sm">
<div id="pc-carousel" class="carousel slide">
<!-- 輪播(Carousel)指標 -->
<ol class="carousel-indicators">
<li data-target="#pc-carouse
class="active"></li>
<li data-target="#pc-carousel" data-slide-to="1"></li>
<li data-target="#pc-carousel
</ol>
<!-- 輪播(Carousel)專案 -->
<div class="carousel-inner">
<div class="item active">
<img src="img/top-banner-01.jpg" alt="First slide">
</div>
<div class="item">
<img src="img/top-banner-02.jpg" alt="First slide">
</div>
<div class="item">
<img src="img/top-banner-03.jpg" alt="First slide">
</div>
</div>
<!-- 輪播(Carousel)導航 -->
<a class="left carousel-control" href="#pc-carousel
<span class="icon-arrow-left glyphicon-chevron-left" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
</a>
<a class="right carousel-control" href="#pc-carousel" role="button" data-slide="next">
<span class="icon-arrow-right glyphicon-chevron-right" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>
</div>
移動端輪播
<div class="container-fluid container-clear hidden-md hidden-lg">
<div id="mb-carousel" class="carousel slide">
<!-- 輪播(Carousel)指標 -->
<ol class="carousel-indicators">
<li data-target="#mb-carousel" data-slide-to="0"
class="active"></li>
<li data-target="#mb-carousel" data-slide-to="1"></li>
</ol>
<!-- 輪播(Carousel)專案 -->
<div class="carousel-inner">
<div class="item active">
<img src="img/trade-m-banner-01.jpg" alt="First slide">
</div>
<div class="item">
<img src="img/trade-m-banner-01.jpg" alt="First slide">
</div>
</div>
<!-- 輪播(Carousel)導航 -->
<a class="left carousel-control" href="#mb-carousel" role="button" data-slide="prev">
<span class="icon-arrow-left glyphicon-chevron-left" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
</a>
<a class="right carousel-control" href="#mb-carousel" role="button" data-slide="next">
<span class="icon-arrow-right glyphicon-chevron-right" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>
&nbs