Bootstrap navbar-fixed-bottom 類用法


要將導航欄固定在底部,請使用 navbar-fixed-bottom 類。

你可以嘗試執行以下程式碼來實現 navbar-fixed-bottom 類 −

示例

線上演示

<!DOCTYPE html>
<html>
   <head>
      <title>Bootstrap Example</title>
      <link href = "/bootstrap/css/bootstrap.min.css" rel = "stylesheet">
      <script src = "/scripts/jquery.min.js"></script>
      <script src = "/bootstrap/js/bootstrap.min.js"></script>
   </head>
   <body>
      <nav class = "navbar navbar-default navbar-fixed-bottom" role = "navigation" style="background: orange;">
         <div class = "navbar-header">
            <a class = "navbar-brand" href = "#">Java Topics</a>
         </div>
         <div>
            <ul class = "nav navbar-nav">
               <li class = "active"><a href = "#">Basics</a></li>
               <li><a href = "#">Interface</a></li>
               <li><a href = "#">Polymorphism</a></li>
               <li><a href = "#">Encapsulation</a></li>
            </ul>
         </div>
      </nav>
   </body>
</html>

更新於: 2020 年 6 月 12 日

319 次瀏覽

開啟 職業生涯

完成課程認證

開始
廣告
© . All rights reserved.