zoukankan      html  css  js  c++  java
  • sticky-footers

    第一种方案

    <!DOCTYPE html>
    <html lang="en">
        <head>
            <meta charset="utf-8">
            <style>
            .clearFix { display: inline-block; }
            .clearFix::after { display: block; content: "."; height: 0; line-height: 0; clear: both; visibility: hidden; }
            .detail { position: fixed; z-index: 100; top: 0; right: 0; width: 100%; height: 100%; overflow: auto; background: rgba(7, 17, 27, 0.8); -webkit-backdrop-filter blur(10px); }
            .detail-wrapper { width: 100%; min-height: 100%; }
            .detail-wrapper .detail-main { margin-top: 64px; padding-bottom: 64px; }
            .detail-close { position: relative; width: 32px; height: 32px; margin: -64px auto 0 auto; clear: both; font-size: 32px; }
            </style>
        </head>
        <body>
        <div class="detail">
            <div class="detail-wrapper clearFix">
                <div class="detail-main">
                    我我我
                </div>
            </div>
            <div class="detail-close">X</div>
    
        </div>
        </body>
    </html>

    第二种方案 flex

    <!doctype html>
    <html lang="en">
    
    <head>
        <meta charset="UTF-8">
        <title>flex-footer</title>
    </head>
    <style>
    body { margin: 0; display: flex; flex-flow: column; min-height: 100vh; }
    main { flex: 1; }
    header { background: pink; }
    footer { background: #333; color: #fff; }
    </style>
    
    <body>
        <header>
            <h1>header</h1>
        </header>
        <main>
            <p>main</p>
        </main>
        <footer>
            <p>footer</p>
        </footer>
    </body>
    
    </html>
  • 相关阅读:
    CAFFE安装(3):cuDNN v4
    监测查询性能(1)
    SQL Server 中的三种分页方式
    使用DBCC SHOW_STATISTICS展示索引的统计信息
    查询表的分配单元数据
    Node.js中的事件
    node-mysql中的连接池代码学习
    Excel动态生成JSON
    使用SignalR实现比特币价格实时刷新
    使用Async同步执行异步函数
  • 原文地址:https://www.cnblogs.com/Doduo/p/7423813.html
Copyright © 2011-2022 走看看