Visit Mozilla.org

DOM:window.scrollByPages

From MDC

(Redirected from window.scrollByPages)

« Gecko DOM Reference

Contents

[edit] Summary

Scrolls the current document by the specified number of pages.

[edit] Syntax

window.scrollByPages(pages) 

[edit] Parameters

  • pages is the number of pages to scroll.
  • pages may be a positive or negative integer.

[edit] Example

// scroll down the document by 1 page 
window.scrollByPages(1);

// scroll up the document by 1 page 
window.scrollByPages(-1);

[edit] Notes

See also window.scrollBy, window.scrollByLines, window.scroll, window.scrollTo.

[edit] Specification

DOM Level 0. Not part of specification.