1

I know that this question was asked before and I checked all the previous answers. I was banging my head against the wall trying all possible changes I could think of. I tried data-target attribute pointing to the ID and the class, I made sure I call jQuery library before I call Bootstrap and it still doesn't work after the the navbar signup elements (2 input fields and Submit buttom) collpase. Everything collapses as it should but than the collapsed version doesn't work. The code is straight from the HTML5 template (the subfolder where they use Bootstrap) available on GitHub. I just can't find the problem. I would appreciate an advice. Here is the code:

 <nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
      <div class="container">
        <div class="navbar-header">
          <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
            <span class="sr-only">Toggle navigation</span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </button>
          <a class="navbar-brand" href="#">BYOB</a>
        </div>
        <div id="navbar" class="collapse navbar-collapse">
          <form class="navbar-form navbar-right" role="form">
            <div class="form-group">
              <input type="text" placeholder="Email" class="form-control-email">
            </div>
            <div class="form-group">
              <input type="password" placeholder="Password" class="form-control-pwd">
            </div>
            <button type="submit" class="btn btn-success" id="knopka">Sign in</button>
          </form>
        </div><!--/.navbar-collapse -->
      </div>
    </nav>
pastrop
  • 21
  • 3

0 Answers0