首页 > 其他 > 详细

圣杯布局

时间:2020-05-26 20:06:05      阅读:55      评论:0      收藏:0      [点我收藏+]
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Document</title>
    <style>
    *{
        margin:0;padding:0;
    }
    .container{
        display: flex;
        height: 100vh;
        flex-direction: column;
    }
    header{
        background: #000;
    }
    section{
        flex:1;
        background: pink;
        display: flex;
    }
    footer{
        background: #000;
    }
    .left{
        background: red;
        flex:0 0 100px;
    }
    .center{
        flex:1;
        background: blue;
    }
    .right{
        flex:0 0 100px;
        background: red;
    }
    </style>
</head>
<body>

<div class=‘container‘>
        
    <header>头部</header>
    <section>
        <div class=‘left‘>左</div>
        <div class=‘center‘>中</div>
        <div class=‘right‘>右</div>
    </section>
    <footer>底部</footer>

</div>
    
</body>
</html>

圣杯布局

原文:https://www.cnblogs.com/1609359841qq/p/12967822.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!