【问题标题】:How can I fix a header that floats to the top of the page on certain browsers and not on others?如何修复在某些浏览器上浮动到页面顶部而不在其他浏览器上浮动的标题?
【发布时间】:2018-05-16 21:43:22
【问题描述】:

当我在浏览器中查看www.kentkercher.com 时,一切正常。

但是,当我在GeoPeeker 中检查它时,H1 会浮动到页面顶部。

我在 Chrome Inspect 中找不到问题。有人可以帮我知道如何解决这个问题。

【问题讨论】:

    标签: html css frontend bootstrap-4


    【解决方案1】:

    只要添加这个 CSS 就可以解决问题::

    .my-auto {
    position: absolute;
        top: 50%;
        left: 0;
        width: 100%;
    }
    

    【讨论】:

    • 谢谢!修复。为将来的情况学习了一些新知识,以防再次出现这种情况。
    猜你喜欢
    • 2011-09-08
    • 1970-01-01
    • 1970-01-01
    • 2015-11-20
    • 2019-07-30
    • 2012-08-02
    • 1970-01-01
    • 2012-04-11
    • 1970-01-01
    相关资源
    最近更新 更多