日期:2014-05-16  浏览次数:20645 次

JS中取得的关于窗口宽高和滚动值的属性列表:(转载)

首先,这是个痛苦的尝试。
  在工作中尝试把一个FLASH居中全屏放置,窗口RESIZE的时候和页面SCROLL的时候都要动态变化,需要取得当前窗口显示区域的WIDTH与HEIGHT,翻了翻资料脑子就一半面一半水搅匀了。类似的参数我全列出来:

window.screen.width: document.body.offsetWidth: document.documentElement.offsetWidth:
window.screen.height: document.body.offsetHeight: document.documentElement.offsetHeight:
window.screen.availWidth: document.body.scrollWidth: document.documentElement.scrollWidth:
window.screen.availHeight: document.body.scrollHeight: document.documentElement.scrollHeight:
window.scrollMaxX:
友情链接: 爱易网 云虚拟主机技术 云服务器技术 程序设计技术 开发网站 APP开发教程
Copyright © 2013-2026 爱易网页 当前在线:1160人  网站在20时47分38秒内访问总人数:247767人 当前 35.05%  粤ICP备18100884号-2