Navbar bootstrap disappears in certain size

Asked

Viewed 808 times

0

We know that the bootstrap has the Visible-Xs, -Sm, -Md, lg and Hidden-Xs, -Sm, -Md, -lg classes to set when the menu will be displayed.

Menu switches to Collapse according to browser size or device resolution.

It turns out, at some point, none of the menus appear: neither the collapsed, nor the complete. When it is small, collapsed appears, which expands with the click. When large, normal menu appears. But when you’re in the middle of it, you don’t have a menu. How do you fix it? I need the full menu to display in lg or Md, and to be collapsed when Sm and Xs.

I do not know if I was clear. Difficult to explain this. rs

  • 1

    Put the code on the menu that you have that makes it easier.... But even without looking may be that there is too much class or missing, but this we can only say looking at code...

  • post your HTML Please.

1 answer

1

I have so my navbar and works perfectly:

<div class="container">
 <div class="navbar-header">
  <a href="index.php" class="navbar-brand">Início</a>
  <button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#navbar-main">
   <span class="icon-bar"></span>
  </button>
 </div>
 <div class="navbar-collapse collapse" id="navbar-main">
  <ul class="nav navbar-nav">           
   <li><a href="xxx.php">XXX</a></li>
   <li><a href="yyy.php">YYY</a></li>
   ...  
  </ul>     
 </div>
</div>

But if you put in your code or a similar example it would be easier to see what’s going on.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.