简体   繁体   English

Bootstrap SImple侧栏-以下内容重叠

[英]Bootstrap SImple Sidebar - Content below overlaps

I'm using the Sidebar Template ( https://startbootstrap.com/template-overviews/simple-sidebar/ ) and i want some content below the sidebar and the content to the right of the sidebar. 我正在使用补充工具栏模板( https://startbootstrap.com/template-overviews/simple-sidebar/ ),我希望补充工具栏下面有一些内容,而补充工具栏右边是一些内容。 It works fine, but when i resize the window the content below overlaps and goes all the way to the top. 它工作正常,但是当我调整窗口大小时,下面的内容重叠并且一直到顶部。

I got something like this: 我得到这样的东西:

<div id="wrapper">

    <!-- Sidebar -->
    <div id="sidebar-wrapper">
        <ul class="sidebar-nav">
            <li class="sidebar-brand">
                <a href="#">
                    Start Bootstrap
                </a>
            </li>
        </ul>
    </div>
    <!-- /#sidebar-wrapper -->

    <!-- Page Content -->
    <div id="page-content-wrapper">
        <div class="container-fluid">
            <div class="row">
                <div class="col-lg-12">
                    <h1>Simple Sidebar</h1>
                    <p>This template has a responsive menu toggling system. The menu will appear collapsed on smaller screens, and will appear non-collapsed on larger screens. When toggled using the button below, the menu will appear/disappear. On small screens, the page content will be pushed off canvas.</p>
                    <p>Make sure to keep all page content within the <code>#page-content-wrapper</code>.</p>
                    <a href="#menu-toggle" class="btn btn-default" id="menu-toggle">Toggle Menu</a>
                </div>
            </div>
        </div>
    </div>
    <!-- /#page-content-wrapper -->

</div>

<!-- /#wrapper -->
<div id="content-below">

</div>

Where should i place the "content-below" container to prevent it from going all the way to the top after resizing? 我应该在哪里放置“ content-below”容器,以防止其在调整大小后一直到达顶部?

just comment out the following section in css: 只需注释掉CSS中的以下部分:

#page-content-wrapper {
    width: 100%;
    /* position: absolute; */
    padding: 15px;
}

see example here codepen 参见示例codepen

enjoy.. :) 请享用.. :)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM