我期待在bxslider頂部放置導航div層。我已經完成了margin-top的常用技巧,帶有負值和z-index:9999以將導航保持在滑塊頂部,但它仍然在滑塊下消失。有沒有辦法將它放在頂部?在bxSlider頂部放置導航Div
這裏是我現有的CSS代碼:
.navigation {
width:100%;
margin-left:26px;
margin-top:-75px;
z-index:9999;
}
.navigationTab {
background-color:#efefef;
-webkit-border-top-left-radius: 2px;
-webkit-border-top-right-radius: 2px;
-moz-border-radius-topleft: 2px;
-moz-border-radius-topright: 2px;
border-top-left-radius: 2px;
border-top-right-radius: 2px;
display:inline-block;
padding-left:3px;
font-size:10px;
color:#212121;
text-transform:uppercase;
height:31px;
line-height:31px;
z-index:9999;
}
.navigationTabRight {
background:url(images/tabRight.png) no-repeat bottom;
width:20px;
display:inline-block;
margin-right:8px;
margin-left:-5px;
height:26px;
z-index:9999;
}
和HTML:
<div class="slider">
<ul class="bxslider">
<li><img src="images/HomeBanners/1.jpg" /></li>
<li><img src="images/HomeBanners/2.jpg" /></li>
</ul>
</div>
<div class="navigation">
<div class="navigationTab">Home</div> <div class="navigationTabRight"> </div>
</div>
完美謝謝:) –