ownerDocument

阅读:23      收藏:0      [点我收藏+]

HTML DOM ownerDocument 属性

实例

返回元素的根元素:

document.getElementById("demo").ownerDocument;


定义和用法

ownerDocument 可返回某元素的根元素。

HTML中, HTML 文档本身是元素的根元素。

越多更多的文档对象请参考我们的 文档对象参考手册


浏览器支持

Internet ExplorerFirefoxOperaGoogle ChromeSafari

所有主要浏览器都支持 ownerDocument 属性


语法

node.ownerDocument

技术细节

返回值: 节点的所有文档,如文档对象。
DOM 版本 Core Level 2 Node Object
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!