Skip to content Skip to sidebar Skip to footer

"animation" In A Navigation Bar With Bootstrap 3

Below is my code and I'm trying to recreate this effect: (http://hideo-html5-css3-bootstrap-website-template.little-neko.com/files/index.html) [When you scroll down the navigaiton

Solution 1:

When the user scolls to an specific position, or in your case when he begins to scroll, you can add an class via jQuery.

Look here for more information:

Leave menu bar fixed on top when scrolled

(Code is taken from the post in the link)

$(window).bind('scroll', function() {
     if ($(window).scrollTop() > 50) {
         $('.menu').addClass('fixed');
     }
     else {
         $('.menu').removeClass('fixed');
     }
});

it is the best when you create an fiddle with your code, so other people can easy modify your code and see whats going on there..

Post a Comment for ""animation" In A Navigation Bar With Bootstrap 3"