0
我有一個旋轉木馬,它工作的很好,但是當我點擊任何點時,dot1消失。我檢查了它的CSS,並且據我所知,當我點擊任何點時,dot1會從某處獲得CSS顯示:無。旋轉木馬指示器dot1不顯示點擊
這是我的代碼點。
<ol class="dotss carousel-indicators" style="margin-top: 20px;z-index: 0;">
<li data-target="#carousel-example-generic" data-slide-to="0" class="abc active" id="a"></li>
<li data-target="#carousel-example-generic" data-slide-to="1" class="abc" id="b"></li>
<li data-target="#carousel-example-generic" data-slide-to="2" class="abc" id="c"></li>
</ol>
這段代碼我用來給它着色。
$("ol li").click(function(){
var id= $(this).attr('id');
if (id == "a") {
$("#a").css("background-color", "white");
$("#b").css("background-color", "#247ba0");
$("#c").css("background-color", "#247ba0");
}
if (id == "b") {
$("#b").css("background-color", "white");
$("#a").css("background-color", "#247ba0");
$("#c").css("background-color", "#247ba0");
}
if (id == "c") {
$("#c").css("background-color", "white");
$("#a").css("background-color", "#247ba0");
$("#b").css("background-color", "#247ba0");
}
});
這是實時鏈接。 http://www.millionmilestech.com/innovision/index.html
旋轉木馬在哪裏? – azad
在頁面左側。一個圖像的左側。 –