BootStrap制作導(dǎo)航條實(shí)例代碼

字號(hào):


    Bootstrap 是一個(gè)用于快速開(kāi)發(fā) Web 應(yīng)用程序和網(wǎng)站的前端框架。本文給大家介紹BootStrap制作導(dǎo)航條實(shí)例代碼,感興趣的朋友一起學(xué)習(xí)吧
    什么是 Bootstrap?
    Bootstrap 是一個(gè)用于快速開(kāi)發(fā) Web 應(yīng)用程序和網(wǎng)站的前端框架。Bootstrap 是基于 HTML、CSS、JAVASCRIPT 的。
    bootstrap 導(dǎo)航條摸索了好久,要不就是左邊和右邊不會(huì)水平對(duì)齊,要不就是顏色不一樣,菜鳥(niǎo)最后終于搞定,直接把代碼放這里,以后直接用
    代碼如下所示:
    <!DOCTYPE html>
    <html lang="zh-cn">
    <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title></title>
    <link href="css/bootstrap.min.css" rel="stylesheet">
    </head>
    <body>
    <nav role = "navigation">
    <div>
    <!-- Brand and toggle get grouped for better mobile display -->
    <div>
    <button type="button" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
    <span>Toggle navigation</span>
    <span></span>
    <span></span>
    <span></span>
    </button>
    <a href="#">KKK</a>
    </div>
    <div id="bs-example-navbar-collapse-1">
    <ul>
    <li><a href="#">首頁(yè) <span></span></a></li>
    </ul>
    <div>
    <ul>
    <li><a href="#">haha<span></span></a></li>
    <li><a href="#">haha<span></span></a></li>
    </ul>
    </div>
    </div>
    </div>
    </nav>
    <script src="js/jquery.min.js"></script>
    <script src="js/bootstrap.min.js"></script>
    </body>
    </html>
    以上所述是小編給大家介紹的BootStrap制作導(dǎo)航條實(shí)例代碼,希望對(duì)大家有所幫助!