栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 软件开发 > Web开发 > Html/CSS > CSS教程

“横向两列布局”扩展-博客页面布局

CSS教程 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

“横向两列布局”扩展-博客页面布局

   根据课程“网页布局基础”中“横向两列布局”的讲解中,自我实践,扩展了原视频代码的内容,实现布局样式在浏览器不同尺寸窗口下保持头部尾部样式不变的美观性。

![图片描述][1]



    
 
 
     横向两列布局
 
 

     *{
  margin: 0;
  padding: 0;
  font-family: 微软雅黑;
  font-size: 20px;
     }
     #wrap{
  width: 90%;
  margin: 0 auto; 
     }
     #head{
  background-color: blue;
  width: 90%;
  position: fixed;
  height: 60px;
  top: 0;
     }
     #mainbody{
  background-color: ;
  overflow: hidden; 
  margin:70px 0; 

  height: 500px;
     }
     .left{
  background-color: green;
  width: 70%;
  height: inherit;
  float: left;
     }
     .right_1{
  background-color: pink;
  width: 28%;
  height: 200px;
  margin-top:; 
  float: right;
     }
     .right_2{
  background-color: gray;
  width: 28%;
  height: 500px; 
  float: right;
  margin-top: 20px;
  bottom: 0px;
     }
     #footer{
  background-color: red;
  height: 60px;
  width: inherit; 
  position: fixed;
  bottom: 0; 
     }
 
    
    
 
     
  头部
     
     
  
  主体左边区域
  主体右上边区域
  主体右下边区域

     
     
  尾部
     
 
    
```

  [1]: http://img1.sycdn.imooc.com/56fbf3be0001b54a13660678.jpg
转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/243556.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号