div各种尺寸属性


网页可见区域宽:document.body.clientWidth

网页可见区域高:document.body.clientHeight

网页可见区域宽:document.body.offsetWidth (包括边线的宽)

网页可见区域高:document.body.offsetHeight (包括边线的宽)

网页正文全部宽度:document.body.scrollWidth

网页正文全部高度:document.body.scrollHeight

垂直滚动距离:document.body.scrollTop

水平滚动距离:document.body.scrollLeft

浏览器上边框到屏幕顶端的距离:window.screenTop

浏览器左边框到左边屏幕边缘的距离:window.screenLeft

屏幕分辨率的高:window.screen.height

屏幕分辨率的宽:window.screen.width

屏幕可用工作区高度:window.screen.availHeight

屏幕可用工作区宽度:window.screen.availWidth


举报

© 著作权归作者所有


1