<!DOCTYPE html>http://127.0.0.1:8020/01HTML/10HTML%E4%B8%ADdiv%E6%A0%87%E7%AD%BE%E7%9A%84%E5%AD%A6%E4%B9%A0.html
<html>
<head>
<meta charset="utf-8">
<title></title>
<style>
.top{
height:100px;
width:100%;
/*背景颜色*/
background-color: red;
}
.tips{
width:100%;
height:40px;
background-color: pink;
}
.center{
width:100%;
height:400px;
background-color: yellow;
}
.bottom{
width: 100%;
height: 100;
background-color: royalblue;
}
.login{
width:350px;
height:300px;
background-color: #ffffff;
/*相对定位*/
position:relative;
left:800px;
top:10px;
}
</style>
</head>
<body>
<!--头部模块-->
<div class="top">
</div>
<!--中间提示-->
<div class="tips"></div>
<!--中间的展示-->
<div class="center">
<div class="login">
</div>
</div>
<!--底部模块-->
<div class="bottom"></div>
</body>
</html>
<!--
div本身是没有哦任何的含义
div:作用就是把网页进行模块化的划分
-->
代码没问题啊 为啥bottom模块没有颜色显示呢