bootstrap_cheat.txt 683 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. ================================================================================
  2. Navbar fixed at top
  3. -------------------
  4. HTML
  5. ----
  6. <nav class="navbar navbar-default navbar-fixed-top">
  7. <div class="container">
  8. ...
  9. </div>
  10. </nav>
  11. CSS
  12. ---
  13. body {
  14. padding-top: 70px; /* Default navbar height: 50px */
  15. }
  16. ================================================================================
  17. Navbar fixed at bottom
  18. ----------------------
  19. HTML
  20. ----
  21. <nav class="navbar navbar-default navbar-fixed-bottom">
  22. <div class="container">
  23. ...
  24. </div>
  25. </nav>
  26. CSS
  27. ---
  28. body {
  29. padding-bottom: 70px; /* Default navbar height: 50px */
  30. }