0
尋找一種方法來添加活動/當前標籤css到ddtablemenu。活動/當前標籤css
默認情況下,加載後始終顯示第一個選項卡。在第二個或第三個選項卡上閃爍後,選項卡顏色變爲紅色(與懸停相同)。當活動的或當前,在底部中央添加菜單arrow.png(.solidblockmenu裏。主動)
<div id="ddtabs3" class="solidblockmenu">
<ul>
<li class="active"><a href="#0" data-toggle="tab" rel="sb1" class="firstelement">Home</a></li>
<li><a href="#1" data-toggle="tab" rel="sb2">DHTML</a></li>
<li><a href="#2" data-toggle="tab" rel="sb3">CSS</a></li>
</ul>
</div>
.solidblockmenu ul{margin: 0;padding: 0;float: left;font: bold 13px Arial;width: 100%;border: 1px solid #625e00;border-width: 1px 0;background: black url(http://www.dynamicdrive.com/dynamicindex1/ddtabmenufiles/media/blockdefault.gif) center center repeat-x;
}
.solidblockmenu li a:hover, .solidblockmenu li a.current{color: white;background: transparent url(http://www.dynamicdrive.com/dynamicindex1/ddtabmenufiles/media/blockactive.gif) center center repeat-x;
}
.solidblockmenu li .active { background-image:url(http://www.asiarooms.com/assets/themes/v1/images/areas/details/menu-arrow.png); background-repeat:no-repeat; background-position:bottom center; }
.solidblockmenu a:hover, .solidblockmenu li .active a { background:#310022 none; }
.solidblockmenu li a.firstelement:hover, .solidblockmenu li .active a.firstelement { background-position:left top; }
在這裏,我在你的jQuery代碼做了速戰速決[HTTP:/ /jsfiddle.net/DJHZb/8/](http://jsfiddle.net/DJHZb/8/) – djthoms
你用哪種語言做? –