新手引导并尝试构建一个导航栏,当它折叠时菜单项消失并显示三个图标栏,单击时显示下拉菜单。当您单击图标栏时,该代码一直有效,但是当单击它时,菜单项不会显示。有什么建议么。
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="css/bootstrap.css">
<title>Untitled Document</title>
</head>
<div class="navbar navbar-default navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data- target=".navbar-ex1-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a href="#" class="navbar-brand"> Text Here</a>
</div>
<div class="collapse navbar-collapse navbar-ex1-collapse">
<ul class="nav navbar-nav">
<li> <a href="#">Home</a></li>
<li> <a href="#">about</a></li>
<li> <a href="#">tutorias</a></li>
<li> <a href="#">contact</a></li>
</ul>
</div>
</div>
</div>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js" ></script>
<script type="text/javascript" src="js/bootstrap.min.js"></script>
</body>
</html>