I am trying to use a very basic smooth scrolling feature with jQuery’s scrollTop function, but no success.
I want that any of the link which has css class “scroll” should always scroll down the page and stop at a div which has a class “stop”.
For example, I have HTML structure like:
<a href="#" class="scroll">Scroll down</a>
<div class = "test">long text</div>
<div class = "stop">Stop here</div>
<div class = "other">text</div>
Try this: