twitter bootstrap - Responsive nav bar not working -
i trying out bootstrap first time , based code on illustration here:
http://twitter.github.com/bootstrap/examples/starter-template.html
i copied main content html code, in version responsive nav bar not work, in when click 'hamburger button' nav elements not appear.
my code:
<!doctype html> <html> <head> <title>bootstrap test</title> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <link href="css/bootstrap.css" rel="stylesheet" media="screen"> <link href="css/main.css" rel="stylesheet" media="screen"> </head> <body> <div class="navbar navbar-inverse navbar-fixed-top"> <div class="navbar-inner"> <div class="container"> <button type="button" class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse"> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button> <a class="brand" href="#">project name</a> <div class="nav-collapse collapse"> <ul class="nav"> <li class="active"><a href="#">home</a></li> <li><a href="#about">about</a></li> <li><a href="#contact">contact</a></li> </ul> </div><!--/.nav-collapse --> </div> </div> </div> <div class="container"> <h1>hello, world!</h1> </div> <!-- /container --> <script src="http://code.jquery.com/jquery.js"></script> <script src="js/bootstrap.js"></script> </body> </html>
my bootstrap files bootstrap customize site. included in build including responsive navbar.
where going wrong.
thanks everyone.
update
i removed main.css file no conflict there. tried 1 time again downloading bootstrap customize page ticked: twitter.github.com/bootstrap/customize.html , still same problem. css file gives me called bootstrap.css not bootstrap-combined.css. there problem bootstraps customize page??
check out: http://jsfiddle.net/panchroma/4xend/
i took exact html , i'm using cdn versions of css , js -- looks me.
http://netdna.bootstrapcdn.com/twitter-bootstrap/2.2.2/css/bootstrap-combined.min.css http://netdna.bootstrapcdn.com/twitter-bootstrap/2.2.2/js/bootstrap.min.js
double check using responsive bootstrap css, bootstrap js file beingness loaded , there isn't in main.css causing conflict.
good luck!
twitter-bootstrap navbar
No comments:
Post a Comment