sevenQu
V2EX  ›  CSS

将 footer 固定到底部。文章内容不足满屏时 footer 在底部,超过满屏时 footer 在内容末尾。 使用 flex 布局,当超过满屏时,没有滚动条,也不能下拉,求解

  •  
  •   sevenQu · Apr 24, 2018 · 3466 views
    This topic created in 2952 days ago, the information mentioned may be changed or developed.

    三个 div,wrapper 包裹 content 和 footer,css 如下

    .wrapper { 
        display: flex; 
        flex-flow: column; 
        min-height: 100vh;
     }
    .content {
        flex: 1; 
    }
    .footer{
        flex: 0 ;
        height:50px ;
    }
    

    在不满屏的状态下,footer 确实在底部,但在超过满屏的时候无法下拉,查看元素,确实存在 footer,50px,求问不能下拉的应该如何处理

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   881 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 22:23 · PVG 06:23 · LAX 15:23 · JFK 18:23
    ♥ Do have faith in what you're doing.