Can a webpage be made to scroll automatically? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Can a webpage be made to scroll automatically?

When using the animate tag with svg shapes, I had to scroll horizontally to keep going along with them. Can I make the webpage scroll along with the shape automatically?

28th Mar 2018, 5:44 PM
Ram Keswani
Ram Keswani - avatar
3 Answers
+ 4
yeah of course, you can use that: var scroll = setInterval(function(){ window.scrollBy(0,1000); }, 2000); for more: http://scraping.pro/make-web-page-to-auto-scroll-down/
28th Mar 2018, 6:50 PM
Baraa AB
Baraa AB - avatar
+ 1
Easy: function pageScroll() { window.scrollBy(0,1); scrolldelay = setTimeout(pageScroll,10); } pageScroll()
28th Mar 2018, 6:14 PM
Niush
Niush - avatar
+ 1
yes,yes you using jquery you can set the pages $("html").scrollTop=50 e.t.c
28th Mar 2018, 6:22 PM
᠌᠌Brains[Abidemi]
᠌᠌Brains[Abidemi] - avatar