如何让页面首部有DOCTYPE声明的页面的body依然支持clientHeight属性?

truesight 2004-04-07 09:36:01
MSDN原文:
What's New for Microsoft® Internet Explorer 6
When you use the !DOCTYPE declaration to specify standards-compliant mode, this object no longer represents the entire surface onto which a document's contents can be rendered. The object can obtain its size from its content, or you can set its size explicitly—like a div object.

意思大概是加了DOCTYPE后,body不再描绘整个内容页面
确实加了DOCTYPE后,document.body.clientHeigh总是等于0

///////////
y有没有办法加了DOCTYPE属性的页面的document.body.clientHeight取得正常的值?

...全文
44 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
rootcn 2004-05-08
  • 打赏
  • 举报
回复
支持的

87,992

社区成员

发帖
与我相关
我的任务
社区描述
Web 开发 JavaScript
社区管理员
  • JavaScript
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧