我在懸停功能上有<a>
標記存在問題。IE懸停在鏈接上不起作用
<a href='#' onClick='javascript:showPrev();'class='prev'> </a>
問題出在CSS代碼中。如果我在a{}
和a:hover{}
中設置了background-color
,圖像將會顯示。否則,如果沒有background-color
或設置爲none
,則圖像不會在懸停時顯示。
這裏是我的CSS
a.next {
outline:none;
position: absolute;
text-decoration:none;
color:black;
z-index: 800;
left: 534px;
top: 0px;
width: 266px;
height: 600px;
display: inline;
}
a.prev {
outline:none;
position: absolute;
text-decoration:none;
color:black;
z-index: 800;
left: 0px;
float:left;
top: 0px;
width: 266px;
height: 600px;
display: inline;
}
#slideshow a.next:hover {
outline:none;
position: absolute;
text-decoration:none;
color:black;
z-index: 800;
left: 534px;
top: 0px;
width: 266px;
height: 600px;
display: inline;
background:url(../images/next.png) 90% 65% no-repeat;
}
#slideshow a.prev:hover {
outline:none;
position: absolute;
text-decoration:none;
color:black;
z-index: 800;
left: 0px;
float:left;
top: 0px;
width: 266px;
height: 600px;
display: inline;
background:url(../images/prev.png) 10% 65% no-repeat;
}
有誰知道可能是什麼問題?提前致謝。
給我們呈現出了問題的URL,請。 –
http://closecurly.kodingen.com/bm/project.html?n=COVERED_CLUSTER&p=1&i=33 這裏是鏈接,您可以在Chrome測試例子,看看它應該怎樣做。然後,即 – Isen