一个简单的网页布局

一个简单的网页布局

<!DOCTYPE html>
    <html>
    <head lang="en">
        <meta charset="UTF-8">
        <title></title>
        <style>
            .header{
                height: 80px;
                width: 970px;
                margin: 0 auto;
                margin-bottom: 10px;
            }
            .header .logo{
                float: left;
                height: 80px;
                width: 270px;
                background-color: red;
            }
            .header .nav{
                float:right;
                height: 42px;
                width: 680px;
                background-color: yellowgreen;
                margin-top: 8px;
            }
            .header .language{
                float:right;
                height: 30px;
                width: 137px;
                background-color: yellowgreen;
            }
            .content{
                height: 435px;
                width: 970px;
                margin: 0 auto;
            }
            .content .ad{
                float:left;
                width: 310px;
                height: 435px;
                background-color: blue;
            }
            .content .content_right{
                float:left;
                height: 435px;
                width: 660px;
            }
            .content .content_right .top{
                height: 400px;
                width: 660px;
            }
            .content .content_right .top .content_r2{
                margin-left: 10px;
                float: right;
                width: 190px;
                height: 400px;
                background-color: pink;
            }
            .content .content_right .top .content_r1{
                float: left;
                width: 450px;
                height: 400px;
                margin-left: 10px;
            }
            .content .content_right .top .content_r1 .news{
                width: 450px;
                height: 240px;
                background-color:orange;
            }
            .content .content_right .top .content_r1 .info{
                margin-top: 10px;
                width: 450px;
                height: 110px;
                background-color: orange;
            }
            .content  .content_right .top .content_r1 .hot{
                margin-top: 10px;
                width: 450px;
                height: 30px;
                background-color: orange;
            }
            .content .content_right .link{
                width: 650px;
                height: 25px;
                background-color: forestgreen;
                margin-top: 10px;
                margin-left: 10px;
            }
            .footer{
                width: 970px;
                height: 35px;
                margin: 0 auto;
                background-color: skyblue;
                margin-top: 10px;
            }
        </style>
    </head>
    <body>
        <!--头部部分开始-->
        <div class="header">
            <div class="logo"></div>
            <div class="language"></div>
            <div class="nav"></div>
        </div>
        <!--头部部分结束-->
    
        <!--内容部分开始-->
        <div class="content">
            <div class="ad"></div>
            <div class="content_right">
                <div class="top">
                    <div class="content_r1">
                        <div class="news"></div>
                        <div class="info"></div>
                        <div class="hot"></div>
                    </div>
                    <div class="content_r2"></div>
                </div>
                <div class="link"></div>
            </div>
        </div>
        <!--内容部分开始-->
    
        <!--页脚部分开始-->
        <div class="footer"></div>
        <!--也叫部分结束-->
    </body>
    </html>

效果

在这里插入图片描述

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值