Jump to content
Sign in to follow this  
matthewjohn938

Need Suggestion for creating a sticky nav bar?

Recommended Posts

What is the best way to create a sticky top navigation bar?

Under a smaller navbar, I have a main navbar and I want the main navbar to be sticky when the page scrolls. I have tried (position: fixed), but when it scrolls, it leaves a space where the bar above it is.

Could you please suggest me the best way to do this?

Thanks

Share this post


Link to post
Share on other sites
On 2/19/2019 at 3:12 PM, Sarah Alfred said:

I would recommend you to visit W3school from there you will find the code for this,because few days back I also had a same problem and W3school came to the rescue. Thanks

Thanks for your suggestion.. I visited the W3school and got the solution..

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...