html - Bootstrap fully 100% height with a sidebar -


i can not understand why height of sidebar on right, not 100%, , when scroll down page, background interrupted.

<nav id="nav" class="nav-primary hidden-xs nav-vertical"> <ul class="nav affix-top" data-spy="affix" data-offset-top="50"> <li><a href=""><i class="icon-user"></i> Профиль</a></li> <li><a href=""><i class="icon-bar-chart"></i> Финансы</a></li> <li><a href=""><i class="icon-sitemap"></i> Товары</a></li> <li><a href=""><i class="icon-signal"></i> Товары (статистика)</a></li> <li><a href=""><i class="icon-envelope-alt"></i> Уведомления (10)</a></li> </ul> </nav> 

enter image description here

life example here

a couple things.

  1. you have 2 position properties set in css #nav.
  2. you should have one, , should position:fixed
  3. there no need top: 0; left: 0 , bottom: 0; if object 100% height , fixed top left, touch bottom.

css should be:

#nav {   position:fixed;   width: 200px;   z-index: 1000;   left: 0;   top: 0;   border-right: 1px solid #162636;   height: 100%; } 

Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -