如何修复引导导航栏重叠?

时间:2018-09-18 13:21:49

标签: html css bootstrap-4

我的引导侧导航出现问题。

我尝试添加页面的任何内容都在导航栏顶部重叠。

您可以在这里看到它- http://35.197.236.48/#

我想要发生的是将内容显示在导航栏的右侧。 我尝试添加行/列/容器,但无法使其正常工作。

谁能看到我哪里出了问题?

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>

<head>
  <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
  <link rel="stylesheet" type="text/css" href="stylesheet">
  <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
  <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
  <script type="text/javascript" src="js"></script>
  <script src="https://use.fontawesome.com/c6d65aa6d0.js"></script>
  <meta http-equiv="content-type" content="text/html; charset=windows-1250">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <meta name="generator" content="PSPad editor, www.pspad.com">
  <title>Tools</title>
</head>

<body>


  <!-- Nav bar, Using bootstrap -->
  <div class="nav-side-menu">
    <div class="brand">Brand Logo</div>
    <i class="fa fa-bars fa-2x toggle-btn" data-toggle="collapse" data-target="#menu-content"></i>

    <div class="menu-list">

      <ul id="menu-content" class="menu-content collapse out">
        <li>
          <a href="#">
            <i class="fa fa-dashboard fa-lg"></i> Dashboard
          </a>
        </li>

        <li data-toggle="collapse" data-target="#products" class="collapsed active">
          <a href="#"><i class="fa fa-gift fa-lg"></i> UI Elements <span class="arrow"></span></a>
        </li>
        <ul class="sub-menu collapse" id="products">
          <li class="active"><a href="#">CSS3 Animation</a></li>
          <li><a href="#">General</a></li>
          <li><a href="#">Buttons</a></li>
          <li><a href="#">Tabs & Accordions</a></li>
          <li><a href="#">Typography</a></li>
          <li><a href="#">FontAwesome</a></li>
          <li><a href="#">Slider</a></li>
          <li><a href="#">Panels</a></li>
          <li><a href="#">Widgets</a></li>
          <li><a href="#">Bootstrap Model</a></li>
        </ul>


        <li data-toggle="collapse" data-target="#service" class="collapsed">
          <a href="#"><i class="fa fa-globe fa-lg"></i> Services <span class="arrow"></span></a>
        </li>
        <ul class="sub-menu collapse" id="service">
          <li>New Service 1</li>
          <li>New Service 2</li>
          <li>New Service 3</li>
        </ul>


        <li data-toggle="collapse" data-target="#new" class="collapsed">
          <a href="#"><i class="fa fa-car fa-lg"></i> New <span class="arrow"></span></a>
        </li>
        <ul class="sub-menu collapse" id="new">
          <li>New New 1</li>
          <li>New New 2</li>
          <li>New New 3</li>
        </ul>


        <li>
          <a href="#">
            <i class="fa fa-user fa-lg"></i> Profile
          </a>
        </li>

        <li>
          <a href="#">
            <i class="fa fa-users fa-lg"></i> Users
          </a>
        </li>
      </ul>
    </div>
  </div>

  <div class="row-one">
    <div class="container-fluid">

      <div class="row" style="margin-top:5%;">

        <div class="col-lg-4 col-md-4 col-sm-6 col-xs-12">
          <ul class="list-group features-box">
            <li class="list-group-item features-box text-center">
              <h4>Number of Hosts</h4>
              <span>.</span>
            </li>
          </ul>
        </div>

        <div class="col-lg-4 col-md-4 col-sm-6 col-xs-12">
          <ul class="list-group features-box">
            <li class="list-group-item features-box text-center">
              <h4>Hosts Online</h4>
              <span>.</span>
            </li>
          </ul>
        </div>

        <div class="col-lg-4 col-md-4 col-sm-6 col-xs-12">
          <ul class="list-group features-box">
            <li class="list-group-item features-box text-center">
              <h4>Hosts Offline</h4>
              <span></span>
            </li>
          </ul>
        </div>

      </div>
    </div>
  </div>

1 个答案:

答案 0 :(得分:2)

在div.row-one中添加一个右上角类,并在css下面给出

.row-one.pull-right {
    width: calc(100% - 300px);
}