capint
3/6/2016 - 7:27 PM

CSS >> Bootstrap >> Navigation bar

CSS >> Bootstrap >> Navigation bar

<nav class="navbar navbar-default navbar-fixed-top">
  <div class="container-fluid">
    <div class="navbar-header">
      <a class="navbar-brand" href="#">Minh Tu's portfolio project</a>
    </div>
    <ul class="nav navbar-nav navbar-right">
      <li class="active"><a href="#home">Home</a></li>
      <li><a href="#about">About</a></li>
      <li><a href="#portfolio">Portfolio</a></li>
      <li><a href="#contact">Contact</a></li>
    </ul>
  </div>
</nav>
http://stackoverflow.com/questions/11124777/twitter-bootstrap-navbar-fixed-top-overlapping-site

Prb: When the navbar is fixed top, all the other content on the site shifts up like the navbar isn't there and the navbar overlaps it.
Solution: body { padding-top: 40px; }