+ 4
Back to top button
I made this page and designed a fixed button in the bottom right corner to jump to the top of the page. I made it work with the # (pound symbol)... can anyone help me to do it same with jQuery ? https://code.sololearn.com/WUS29rwzz5tv/?ref=app
6 Respuestas
+ 4
Then
<button onclick="$('body').animate({scrollTop:0},500)" ><span>Top</span></button>
or used loop as he said for faster optimize
+ 8
<button onclick="$(window).scrollTop(0)"><span>Top</span></button>
+ 2
how can we make the scrolling smooth?
+ 2
Thx
+ 1
Maybe if you use a loop?