1

Multiple navbars on the same page dropdowns will overlapped by other navbars, see:

enter image description here

How to prevent this?

Anshad Vattapoyil
  • 23,145
  • 18
  • 84
  • 132
Bass Jobsen
  • 48,736
  • 16
  • 143
  • 224

1 Answers1

4

Although navbars are meant for singular use you are free to use more as one navbar per page. Multiple navbars on the same page will have the same z-index (1000) so dropdowns may overlap. When using more navbars give each an different z-index (and id). The second z-index should to be lower than the first one, etc.

B.e. with having navbars like: <nav id="navbar1" class="navbar" role="navigation"> <nav id="navbar2" class="navbar" role="navigation"> <nav id="navbar3" class="navbar" role="navigation"> <nav id="navbar4" class="navbar" role="navigation">

set the z-indexes by:

#navbar2 {z-index:999;}
#navbar3 {z-index:998;}
#navbar4 {z-index:997;}
Bass Jobsen
  • 48,736
  • 16
  • 143
  • 224