我在我的頁面上有5 <div>
標籤。無法將浮動div標籤放在他們所需的地方
- 容器
<div>
- 頭
<div>
- 左側面板
<div>
- 中間面板
<div>
- 右側面板
<div>
左圖,中圖和右面板<div>
被放置旁邊由sid e使用CSS float left
。現在,當取出的數據顯示在中間面板<div>
中並且其高度根據獲取的數據量開始增加時出現問題。如圖所示,左側面板<div>
保留在假定位置,但右側面板<div>
更改了其邊距。
此圖片說明的確切情況。以下是我的CSS。
*{
margin:0;
padding:0;
font-family:Arial, Helvetica, sans-serif;
}
.container{
margin:0 auto;
padding:0;
}
.header{
height:100px;
width:100%;
}
.left_panel{
width:130px;
float:left;
}
.middle_panel{
width:70%;
float:left;
}
.right_panel{
float:right;
width:130px;
}
請幫我解決這個問題。謝謝。
一張圖片勝過1K字,但小提琴是價值10萬個字。你可以發佈一個顯示這種行爲? – TreeTree
哎呀,我會解決你的HTML。 – isherwood
但是誰知道他在右欄有什麼瘋狂的內容?也許它有一個巨大的頂部邊緣的段落。 – TreeTree