javascript - Scroll a website via Window.Scroll -
javascript - Scroll a website via Window.Scroll -
hey guys have been trying scroll website adding little piece of code inspect element.
the code
function pagescroll() { window.scrollby(0,50); // horizontal , vertical scroll increments scrolldelay = settimeout('pagescroll()',100); // scrolls every 100 milliseconds } <a href="javascript:pagescroll()">scroll page</a>
when add together code on inspect element link appear on webpage doesnt scroll downwards ..
hope guys can help me ..!!!
<html> <body> <script> function pagescroll() { window.scrollby(0,50); // horizontal , vertical scroll increments scrolldelay = settimeout('pagescroll()',100); // scrolls every 100 milliseconds } </script> <a href="javascript:pagescroll()">scroll page</a> <p>some big content scrolling ....</p> </body> </html>
above code working fine.
javascript html css
Comments
Post a Comment