ブラウザ ウィンドウのサイズ変更に関して、Stackoverflow と同様のレイアウトにしたい Web サイトがあります。
だから私は次のCSSを持っています:
#site-container {
margin: 0px auto;
text-align: left;
width: 100%;
zoom: 1;
position: relative;
}
body {
font-family: arial, helvetica, sans-serif;
font-size: 81.25%;
background-color: #fbf9ef;
}
#div-menu {
display: inline;
}
#header {
width: 990px;
height: 80px;
margin-left : 127px;
margin-right : 127px;
margin-bottom: 12px;
margin-top: 20px;
border-bottom: 1px solid #c0c0c0;
}
#content {
width: 990px;
margin-left : 127px;
margin-right : 127px;
}
ただし、ブラウザー ウィンドウのサイズを変更すると、Stackoverflow のように動作しません。どういうわけか、Stackoverflow がフローティングのように見え、ブラウザー ウィンドウのサイズに応じてマージンが自動的に縮小されます。
ありがとう