課程
/前端開發
/HTML/CSS
/如何用CSS進行網頁布局
幫忙看看哪里有問題
2015-11-25
源自:如何用CSS進行網頁布局 5-3
正在回答
.left要有left、top值。.main{height:600px; position:relative; background-color:red;}
.left{ width:200px;height:600px;position:absolute;left:0;top:0;background-color:blue;}
.right{height:600px;margin:0 0 0 210px;background-color:#9acc99;}
剛才回答錯了,不好意思
松紫夢 提問者
寬度自適應可以把寬度設為一個百分比的數。寫為.right{height:600px;width:60%;float:right}
沒有設置right、left的float
舉報
用最簡潔的案例教你布局的那些知識,這是前端工程師基本技能
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號-11 京公網安備11010802030151號
購課補貼聯系客服咨詢優惠詳情
慕課網APP您的移動學習伙伴
掃描二維碼關注慕課網微信公眾號
2015-11-29
.left要有left、top值。.main{height:600px; position:relative; background-color:red;}
.left{ width:200px;height:600px;position:absolute;left:0;top:0;background-color:blue;}
.right{height:600px;margin:0 0 0 210px;background-color:#9acc99;}
剛才回答錯了,不好意思
2015-11-29
寬度自適應可以把寬度設為一個百分比的數。寫為.right{height:600px;width:60%;float:right}
2015-11-25
沒有設置right、left的float