我是bootstrap的新手我知道在bootstrap中创建一个基本的导航栏我想知道如何创建一个类似于http://demo.vnthemepro.com/vt_ovansport/?___store=default
的导航栏HTML:
<div class="navbar navbar-default navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<a href="../" class="navbar-brand">Smart</a>
<button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#navbar-main">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<div class="navbar-collapse collapse" id="navbar-main">
<ul class="nav navbar-nav">
<li><a href="help/">Help</a></li>
<li><a href="about/">about</a></li>
<li><a href="contact/">contact</a></li>
</ul>
</div>
</div>
</div>
答案 0 :(得分:0)
<div role="navigation" class="row navbar navbar-default navbar-static-top">
<div class="container">
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<li class="">
<a data-toggle="dropdown" class="dropdown-toggle" href="#" aria-expanded="false"> Shop <i class="fa fa-angle-down"></i></a>
<ul class="dropdown-menu multi-level">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
</ul>
</li>
<li>
<a data-toggle="dropdown" class="dropdown-toggle" href="#"> DIY Guides <i class="fa fa-angle-down"></i></a>
<ul class="dropdown-menu multi-level">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
<li>
<a data-toggle="dropdown" class="dropdown-toggle" href="#">EPDM Calculator <i class="fa fa-angle-down"></i></a>
<ul class="dropdown-menu multi-level">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
<li class="divider"></li>
</ul>
</li>
<li class="">
<a data-toggle="dropdown" class="dropdown-toggle" href="#" aria-expanded="false"> Adhesives & Sealants <i class="fa fa-angle-down"></i></a>
<ul class="dropdown-menu multi-level">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
</ul>
</li>
<li>
<a data-toggle="dropdown" class="dropdown-toggle" href="#"> Trade<i class="fa fa-angle-down"></i></a>
<ul class="dropdown-menu multi-level">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
<li>
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Tutorials <i class="fa fa-angle-down"></i></a>
<ul class="dropdown-menu multi-level">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a data-toggle="dropdown" class="dropdown-toggle" href="#">Dropdown</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
<li class="divider"></li>
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
<ul class="dropdown-menu">
<li class="dropdown-submenu">
<a href="#"><span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-home fa-stack-1x fa-inverse"></i>
</span> Lorem ipsum dolor</a>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div><!--/.nav-collapse -->
</div>