HTML DOM Document implementation attribute
- 上一页 images
- 下一页 importNode()
- 返回上一层 HTML DOM Documents
definition and usage
implementation
The property returns the DOMimplementation object that handles the document.
Warning!
DOM 1 Recommendation (1998) specifies only one method for this object: hasFeature().
The hasFeature() method is used to check if the browser supports the DOM module:
let answer = document.implementation.hasFeature("DOM", "1.0");
The question is: all modern browsers always return true
.
instance
Example 1
Does this document have the DOM 1.0 feature?
document.implementation.hasFeature("DOM", "1.0");
Example 2
Does this document have the TESLA X feature?
document.implementation.hasFeature("TESLA", "X");
syntax
document.implementation
return value
type | description |
---|---|
object |
DocumentImplementation object, the implementation object of the document. |
browser support
document.implementation
是 DOM Level 1 (1998) 特性。
所有浏览器都支持它:
Chrome | IE | Edge | Firefox | Safari | Opera |
---|---|---|---|---|---|
Chrome | IE | Edge | Firefox | Safari | Opera |
支持 | 9-11 | 支持 | 支持 | 支持 | 支持 |
- 上一页 images
- 下一页 importNode()
- 返回上一层 HTML DOM Documents