2013-09-01 2 views
-1

작동하지 나는이 있습니다 avatardiv의CSS - Z- 인덱스

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 

<html> 
<head> 
    <title>Untitled</title> 

    <style> 
    .avatardiv{width:48px;height:48px;z-index:20} 
    .avatardiv a{width:48px;height:48px} 
    .postdiv{width:100%;margin-top:-48px;z-index:10} 
    </style> 

</head> 

<body> 

<div class="avatardiv"><a href="http://google.com"><img src="" /></a></div> 
<div class="postdiv">test test test test test test test test test test ....</div> 

</body> 
</html> 

Z- 인덱스 파이어 폭스에서 작동하지 않습니다. IE에서 img를 클릭 할 수는 있지만 FireFox에서는 클릭 할 수 없습니다.

모든 솔루션?

답변

2

사용 위치 : Z 인덱스 만 위치 요소에 작동 (위치 : 사용자가 Z- 색인을 사용하는 상대 재산권 난이

<style> 
    .avatardiv{width:48px;height:48px;z-index:20;position:relative} 
    .avatardiv a{width:48px;height:48px} 
    .postdiv{width:100%;margin-top:-48px;z-index:10;position:relative} 
    </style>