| Article Introduction: do move, drag the commonly used JS properties. |
1.clientHeight, ClientWidth:
These two properties show, in general, the pixel height and width of the element's content. Theoretically, these measurements do not consider any entry through the stylesheet
The page margins, borders, and so on in the element.
2.clientleft,clienttop:
These two return the thickness of the border around the element, and if you do not specify a border or do not locate the modifier, his value is 0.
3.scrollleft,scrolltop:
If the elements are scrollable, you can use these properties to get how far the element scrolls in both horizontal and vertical directions, in pixels.
These values are always 0 for elements that cannot be scrolled.
4.scrollheight,scrollwidth:
No matter how many objects are visible on the page, they get the whole. Top
<script language= "JavaScript" >
var s = "";
s + = "\ r \ n page visible area wide:" + document.body.clientWidth;
s + + "\ r \ n page visible Area High:" + document.body.clientHeight;
s + + "\ r \ n" page visible area High: "+ Document.body.offsetWeight +" (including the edge of the width);
s + + "\ r \ n" page visible area High: "+ Document.body.offsetHeight +" (including the edge of the width);
s + + "\ r \ n page text full text width:" + document.body.scrollWidth;
s + + "\ r \ n" page full text High: "+ document.body.scrollHeight;
s + + "\ r \ n Pages are rolled High:" + document.body.scrollTop;
s + + "\ r \ n page is rolled to the left:" + document.body.scrollLeft;
s + + "\ r \ n Page body part:" + window.screentop;
s + + "\ r \ n Page body part left:" + window.screenleft;
s + + "\ r \ n screen resolution of High:" + window.screen.height;
s + + "\ r \ n Screen resolution width:" + window.screen.width;
s + = "\ r \ n Screen available working area height:" + window.screen.availHeight;
s + = "\ r \ n Screen available working area width:" + window.screen.availWidth;
alert (s);
</SCRIPT>