「JavaScript」カテゴリーアーカイブ

Window size and scrolling

JavaScript tutorial - Window size and scrolling

window.innerHeight/Width
Provided by most browsers, but importantly, not Internet Explorer.
document.body.clientHeight/Width
Provided by many browsers, including Internet Explorer.
document.documentElement.­clientHeight/Width
Provided by most DOM browsers, including Internet Explorer.

ふくろうの備忘録 » クライアントの表示領域を得る