Advertisement
Guest User

Untitled

a guest
Nov 24th, 2014
142
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. <SCRIPT type="text/javascript">
  2. function scrollpage() {
  3. function scroll() {
  4. Height= document.body.scrollHeight;
  5. if (status == 0) {
  6. i = i + 10;
  7. window.scrollBy(0, 20);
  8. if (i >= Height) {
  9. status = 1;
  10. i=Height;
  11. window.scrollBy(0, -40);
  12. }
  13. } else {
  14. i = i - 10;
  15. window.scrollBy(0, -20);
  16. if (i <= 1) {
  17. status = 0;
  18. }
  19. }
  20. setTimeout(scroll, 50);
  21. }
  22. scroll();
  23. }
  24. var Height;
  25. var i = 1,status = 0;
  26. window.onload=scrollpage
  27. </SCRIPT>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement