I am trying to make a portfolio page. Technologies I am using are HTML, CSS and jQuery. However, I am stuck at a problem involving scrolling my page up and down. U see, while I scroll down, I want to add a class on the navbar link, corresponding to the div I am on the page. While it happens, to some extent, while scrolling down, it just messes up while scrolling up.
Following is my code …
Any help is appreciated. Thank You.