首页 > 解决方案 > 滚动条显示在页面底部

问题描述

我正在创建一个 HTML 文档,在添加一个新部分后,页面底部会出现一个滚动条,这可能会将布局推向右侧。

我设法缩小导致问题的原因。它发生在我添加以下代码后:

HTML

<section id="services">
        <div class="row">
            <div class="container">
                <div class="col-md-12">
                    <div class="content-title">
                        <h3 class="text-center">Szolgáltatásaink</h3>
                    </div>
                </div>
            </div>
        </div>
    </section>

CSS:

.content-title {
    padding-top: 4rem;
}

.content-title h3 {
    color: #333333;
    text-transform: uppercase;
    position: relative;
    padding-bottom: 2rem;
}

.content-title h3:after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    width: 15%;
    height: .4rem;
    background:  #ff5f06;
    margin: 0 auto;
}

这是实时应用程序:https ://avrasys.hu/

标签: htmlcssuser-interfacelayoutmargin

解决方案


我查看了您的实时站点https://avrasys.hu/,发现从课堂中删除margin-left: -15px;margin-right: -15px;退出.row课程可以解决问题。


推荐阅读