61,110
社区成员
发帖
与我相关
我的任务
分享
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="main.aspx.cs" Inherits="main" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>Caterpillar</title>
<style type="text/css">
<!--
* {
margin: 0px;
padding: 0px;
}
body {
height: 100%;
}
#container {
margin-right: auto;
margin-left: auto;
}
#header {
background-color: #003300;
height: 60px;
color: #FFFFFF;
}
#leftdiv {
background-color: #99CC00;
float: left;
width: 200px;
}
#rightdiv {
background-color: #666600;
margin-left: 200px;
}
#footer {
clear: both;
height: 30px;
color: #FFFFFF;
background-color: #990000;
}
-->
</style>
</head>
<body>
<div id="container">
<div id="header">header</div>
<div id="content">
<div id="leftdiv">leftdiv</div>
<div id="rightdiv">
<p>rightdiv</p>
</div>
</div>
<div id="footer">footer</div>
</div>
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh-CN">
<style type="text/css">
html, body {
margin: 0;
overflow: hidden;
}
* html, * html body {
margin: 0;
height: 100%;
}
* html #outer {
width: 100%;
height: 100%;
overflow: hidden;
position: relative;
}
.fixed {
position: fixed;
}
* html .fixed {
position: absolute;
}
.fixed {
bottom: 0;
width: 100%;
}
.header {
height: 50px;
background: #ff0;
}
.footer {
height: 50px;
background: #f00;
}
.sidebar {
float: left;
width: 210px;
background: #0f0;
height: 9999px;
}
.content {
margin-left: 200px;
background: #00f;
height: 9999px;
}
</style>
<body>
<div id="outer">
<div class="wrapper">
<div class="header">header</div>
<div class="container" style="background:#00f">
<div class="sidebar">sidebar</div>
<div class="content">content</div>
</div>
</div>
</div>
<div class="fixed">
<div class="footer">footer</div>
</div>
</body>
</html>
#leftdiv{height:auto!important;height:360px;min-height:360px;}
#rightdiv{height:auto!important;height:360px;min-height:360px;}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>Caterpillar</title>
<style type="text/css">
<!--
* {
margin: 0px;
padding: 0px;
}
body {
height: 100%;
}
#container {
margin-right: auto;
margin-left: auto;
}
#header {
background-color: #003300;
height: 60px;
color: #FFFFFF;
}
#leftdiv {
background-color: #99CC00;
position:absolute;
left:0%;
right:80%;
top:60px;
bottom:50px;
width: 200px;
}
#rightdiv {
background-color: #666600;
/* margin-left: 200px;*/
position:absolute;
left:15.5%;
right:0%;
top:60px;
bottom:50px;
}
#footer {
clear: both;
position:absolute;
bottom:1px;left:1px;right:1px;
height: 50px;
color: #FFFFFF;
background-color: #990000;
}
-->
</style>
</head>
<body>
<div id="container">
<div id="header">header</div>
<div id="content">
<div id="leftdiv">leftdiv</div>
<div id="rightdiv">
<p>rightdiv</p>
</div>
</div>
<div id="footer">footer</div>
</div>
</body>
</html>