If so, it just requires a small piece of jQuery which will attach an addition class to your nav div (for example, ‘.sticky’) and turn it to a fixed position once you scroll past the navigation with top, bottom & margins of 0.
Great little code sample here! I am working with bootstrap3.1 and tried for 4 hours to do this sticky fixed nav trick. I did try different sticky-nav plugins but nothing worked.. I try to stay away from many plugins because they are bloated.. look at bootstrap3 scrollspy and afix.. for example.
but then I tried one last time and found your example. It is so simple and easy.. and it works great.. even in responsive mode.
Viewing 14 posts - 1 through 14 (of 14 total)
You must be logged in to reply to this topic.
*May or may not contain any actual "CSS" or "Tricks".