我正在使用补充工具栏模板(https://startbootstrap.com/template-overviews/simple-sidebar/),我希望边栏下方有一些内容,侧边栏右侧有内容。它工作正常,但是当我调整窗口大小时,下面的内容会重叠并一直到顶部。
我有这样的事情:
<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>
我应该在哪里放置&#34;以下内容&#34;容器,以防止它在调整大小后一直到顶部?
答案 0 :(得分:1)
只需在css中注释掉以下部分:
#page-content-wrapper {
width: 100%;
/* position: absolute; */
padding: 15px;
}
请参阅此处示例codepen
享受.. :)