Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Nurul Ahsan
2,039 Pointshtml and css
I know how to make navbar always fixed top.
But I dont know how to make after scroll navbar fixed top. Pls help me.
4 Answers
David Tonge
Courses Plus Student 45,640 PointsYou'll need javascript to accomplish that. Example here: http://codepen.io/senff/pen/ayGvD
David Tonge
Courses Plus Student 45,640 PointsI think I'm understanding what you're saying but I'm going to ask just to clarify. So, you know how to create a navbar that is fixed to the top of the screen but it moves when the page is scrolled?
Nurul Ahsan
2,039 PointsMr.David Tonge, I know how to creat a navbar that is fixed to the top of the screen and it does not moves when the page scroll.
But i like to creat navbar any where of the body and after scroll that navbar will be fixed to the of the screen.
Nurul Ahsan
2,039 PointsMr.David Tonge, Have a nice day to you . I know how to creat a navbar that is fixed to the top of the screen and it does not moves when the page scroll.
But i like to creat navbar any where of the body and after scroll that navbar will be fixed to the of the screen.
Nurul Ahsan
2,039 PointsHello Mr.David Tonge Good day to you.I am very much pleased on getting your mail with problem solution.Thanks for your nice cooperation. I hope your such cooperation will continue. Thanks again. nurulahsan
David Tonge
Courses Plus Student 45,640 PointsNo problem. I have no problem helping the treehouse community.