一:代码见下
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
*{
margin: 0;
padding: 0;
}
html,body{
height: 100%;
}
/* 一级上、中、下内容格式设置 */
header,footer{
height: 50px;
line-height: 50px;
background: orange;
text-align: center;
/* 文本居中 */
}
section{
height: calc(100% - 100px);
/* calc计算函数 */
}
/* 二级左、中、右内容