综合实战

<pre>

制作有路网首页

image

有路网首页布局框架制作

划分区域,确定div

测量各个区域的宽高

使用浮动对网页进行布局

image
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>有路网整体布局</title>
    <link href="reset.css" rel="stylesheet">
    <style type="text/css">

        .top1{
            height: 31px;
            background-color: gray;
        }
        .top2{
            height: 134px;
            background-color: green;
        }
        .top3{
            height: 40px;
            background-color: red;
            /*margin-top: 30px;*/
        }
        .main{
            width: 1200px;
            margin:0px auto;
            /*position: relative;*/
        }
        .main_top{
            width: 990px;
            height: 30px;
            background-color: pink;
            float: left;

        }
        .main_left{
            width: 210px;
            height: 968px;
            background-color: blue;
            float: left;
        }
        .main_right{
            width: 220px;
            height: 937px;
            background-color: blue;
            float: right;
        }
        .d1{
            float: left;
            width: 750px;
            height: 340px;
            background-color: red;
            margin:0px 10px; 
        }
        .d2{
            float: left;
            width: 750px;
            height: 597px;
            background-color: green;
            margin:0px 10px; 
        }
    </style>
</head>
<body>
    <div class="top1"></div>
    <div class="top2"></div>
    <div class="top3"></div>
    <div class="main">

        <div class="main_left"></div>
        <div class="main_top"></div>
        <div class="main_right"></div>
        <div class="d1"></div>
        <div class="d2"></div>
    </div>
</body>
</html>

整合各章中的局部布局案例

©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

  • 制作有路网首页 有路网首页布局框架制作 划分区域,确定div测量各个区域的宽高使用浮动对网页进行布局 Flexbo...
    __豆约翰__阅读 4,147评论 0 0
  • 问答题47 /72 常见浏览器兼容性问题与解决方案? 参考答案 (1)浏览器兼容问题一:不同浏览器的标签默认的外补...
    _Yfling阅读 14,703评论 1 92
  • Android 自定义View的各种姿势1 Activity的显示之ViewRootImpl详解 Activity...
    passiontim阅读 176,729评论 25 709
  • 找到生活的平衡,享受生活中的点点滴滴 一件深色T恤 一条舒适的裤子 一双轻便的旅游鞋
    d39be4677381阅读 1,355评论 0 0
  • 男人一生最好的投资不是房,不是车,而是..... 2018-01-15 男人一生最好的投资不是房,不是金,不是股票...
    拼搏_3792阅读 1,378评论 0 0

友情链接更多精彩内容