css浮动1

<head>
        <meta charset="utf-8" />
        <title>练习一</title>
        <style type="text/css">
            *{
                margin: 0px;
                padding: 0px;
            }
            .header{
                height: 60px;
                background: cornflowerblue;
            }
            .box{
                height: 60px;
                width: 1000px;
                background: aquamarine;
                margin: 0PX auto;
             }
             .header-content{
                 height: 500px;
                 background: lightgray;
              }
              .box-p{
                  width: 1000px;
                  height: 500px;
                  background: darkgoldenrod;
                  margin: 0px auto;
              }
              .box-p1{
                  height: 500px;
                  width: 100px;
                  background: cadetblue;
                  float: left;
              }
              .box6{
                  width: 500px;
                  height: 500px;
                  background: chartreuse;
                  float: left;
              }
              .right{
                  width: 400px;
                  height: 500px;
                  background: blue;
                  float: left;
              }
              .box-p11{
                  height: 120px;
                  background: black;
              }
              .box11{
                  width: 1000px;
                  height: 120px;
                  background: chocolate;
                  margin: 0px auto;
              }
        </style>
    </head>
    <body>
        <div class="header">
            <div class="box"></div>
        </div>
        <div class="header-content">
            <div class="box-p">
                <div class="box-p1">
                </div><div class="box6">
                </div><div class="right"></div>
            </div>
        </div>
        <div class="box-p11">
            <div class="box11"></div>
        </div>
    </body>
</html>

 

posted @ 2019-01-24 18:47  forwardq  阅读(162)  评论(0编辑  收藏  举报