DOM:element.scrollHeight
From MDC
Contents |
[edit] scrollHeight
Height of the scroll view of an element; it includes the element padding but not its margin.
[edit] Syntax and values
var intElemScrollHeight = document.getElementById(id_attribute_value).scrollHeight;
intElemScrollHeight is a variable storing an integer corresponding to the scrollHeight pixel value of the element. scrollHeight is a read-only property.
[edit] Description
An element's scrollHeight is a measurement of the height of an element's content including content not visible on the screen due to overflow.
If the element's content generated a vertical scrollbar, the scrollHeight value is equal to the minimum clientHeight the element would require in order to fit all the content in the viewpoint without using a vertical scrollbar. When an element's content does not generate a vertical scrollbar, then its scrollHeight property is equal to its clientHeight property.
[edit] Example
padding-top
Gentle, individualistic and very loyal, Birman cats fall between Siamese and Persian in character. If you admire cats that are non aggressive, that enjoy being with humans and tend to be on the quiet side, you may well find that Birman cats are just the felines for you.
All Birmans have colorpointed features, dark coloration of the face, ears, legs and tail.
Cat image and text coming from www.best-cat-art.com
padding-bottom
[edit] Specification
scrollHeight is part of the MSIE's DHTML object model. scrollHeight is not part of any W3C specification or technical recommendation.
[edit] Notes
scrollHeight is a property of the DHTML object model which was first introduced by MSIE. It is referred to as the height of an element's physical scrolling view.
