javascript window scrollX, scrollY
| scrollX, scrollY | NN 6 IE n/a DOM n/a |
| Read-only | |
|
Return the pixel distance the window is scrolled along the horizontal (scrollX) and vertical (scrollY) axes. To determine these values in IE, you must take into account compatibility mode settings in IE 6 (see the DOCTYPE element). In backward compatibility mode and in IE for Macintosh, use the document.body.scrollLeft and document.body.scrollTop properties. In IE 6 standards compatibility mode (where document.compatMode == "CSS1Compat"), use document.body.parentNode.scrollLeft and document.body.parentNode.scrollTop to get the scroll values of the html element. |
|
| Example | |
var scrolledDown = window.scrollY; |
|
| Value | |
Integer. |
|
| Default | |
0 |
|
Previous: javascript window scrollbars
- #12008-11-20[Quote]Thanx A lot boss.....thanQ very much
- #22008-12-11[Quote]Thanks you ^_^
2220,Nickname,Homepage or email,Comments here,Add comment
