[問題] 關於position:absolute的問題
各位大大好,小弟我想請教一個問題
目前相關的設定如下
html部份
<div id="container">
<div id="wave_left"></div><!--end of wave_left-->
<div id="wave_right"></div><!--end of wave_right-->
</div><!--end of container-->
CSS部分
#container{
width:1000px;
height:580px;
margin:0px auto;
background:url('ui/container_bg.png') left top no-repeat;
z-index:1;
}
#wave_left{
background:url('ui/wave_left.png') left top no-repeat;
width:100px;
height:325px;
position:absolute;
right:-100px;
}
#wave_right{
background:url('ui/wave_right.png') left top no-repeat;
width:100px;
height:325px;
position:absolute;
right:-100px;
}
小弟我想做的是讓#wave_left和#wave_right能夠剛好接在#container的兩側
目前顯示結果是都OK,可以剛好接續
但是問題在於若視窗縮小到1024px以下,#wave_left會出現在畫面外沒有問題
但#wave_right卻不會出現在畫面外,而會出現水平的捲軸
請問有沒有辦法解決position:absolute在這裡出現的這個問題ꄊ謝謝各位大大
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 59.124.247.22
推
06/05 13:34, , 1F
06/05 13:34, 1F
→
06/05 13:35, , 2F
06/05 13:35, 2F
不好意思,是在打上來的時候手誤...囧rz
※ 編輯: robert38 來自: 59.124.247.22 (06/05 13:52)
推
06/05 14:22, , 3F
06/05 14:22, 3F
→
06/05 14:24, , 4F
06/05 14:24, 4F
對,目前的狀況就是這樣
不知道有沒有辦法消除縮小視窗時的水平捲軸>.<
※ 編輯: robert38 來自: 59.124.247.22 (06/05 15:49)
推
06/05 16:08, , 5F
06/05 16:08, 5F
→
06/05 16:17, , 6F
06/05 16:17, 6F