嗨我想用相對位置來放置我的覆蓋div div-profile-top div後面。 但是,由於某種原因,它會在封面div通常會出現的地方留下空隙。我究竟做錯了什麼?相對定位留下缺口
的jsfiddle:http://jsfiddle.net/QPZEk/1/
CSS:
#cover-wrap {
position: relative;
top: -65px;
height: 250px;
width: 470px;
background: url('https://sphotos-a.xx.fbcdn.net/hphotos-
ash3/540880_10200267172913759_929968936_n.jpg') no-repeat center center;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}
不知道這部影片的聲音是什麼好,但是它演示了相對定位:http://www.youtube.com/watch?v=8BZS--kcMZ0 – cimmanon 2013-04-04 20:31:37