我希望我的布局如下图所示
这是我尝试过的代码:
CSS
body {
margin: 0;
padding: 0;
background-color: #faf8f6;
font-family:'Segoe UI', Verdana, Arial;
font-size: 13px;
color: #2c2c2c;
}
img, img a, img a:hover {
border: none;
}
p {
margin: 0;
padding: 0;
}
#main-wrapper {
margin: 0;
padding: 0;
width: 100%;
min-height: 100%;
position: fixed;
}
#header {
margin: 0;
padding: 0;
width: 100%;
height: 100px;
background-color: #faf8f6;
}
#left-logo {
margin: 38px 0 26px 35px;
width: 300px;
height: 36px;
float: left;
}
#left-logo p {
font-size: 32px;
color: #000000;
text-align: left;
line-height: 26px;
}
#left-logo p span {
color: #d4102b;
font-weight: bold;
}
#right-logo {
margin: 15px 35px 15px 0;
width: 217px;
height: 70px;
float: right;
}
#menu-wrapper {
margin: 0;
padding: 0;
width: 100%;
height: 28px;
background-color: #948e8a;
border-top: 1px solid #5a4736;
border-bottom: 1px solid #5a4736;
}
#body-wrapper {
top: 130px;
bottom: 25px;
width: 100%;
position: fixed;
}
#left-menu-wrapper {
width: 199px;
height: 100%;
float: left;
background-color: #948e8a;
border-right: 1px solid #5a4736;
}
#content-wrapper {
width: calc(100%-200px);
margin: 0 0 0 200px;
height: 100%;
}
#footer {
bottom: 0;
height: 24px;
width: 100%;
background-color: #948e8a;
border-top: 1px solid #5a4736;
position: fixed;
}
#footer p {
margin: 0 35px 0 0;
text-align: right;
line-height: 24px;
color: #ffffff;
font-size: 12px;
}
HTML
<body>
<form id="form1" runat="server">
<div id="main-wrapper">
<div id="header">
<div id="left-logo">
<p><span>123</span> India</p>
</div>
<div id="right-logo">
<img src="Css/Images/logo.gif" />
</div>
<div class="clr"></div>
</div>
<div id="menu-wrapper"></div>
<div id="body-wrapper">
<div id="left-menu-wrapper"></div>
<div id="content-wrapper"> </div>
</div>
<div id="footer">
<p>© 2013. 123India. All rights reserved.</p>
</div>
</div>
</form>
</body>
这是 JS Fiddle 的现场演示。