DocumentType: systemId 属性
DocumentType 的只读属性 systemId 返回关联 DTD 的 URL。
对于人工(synthetic)创建的 DocumentType,此属性反映在 DOMImplementation.createDocumentType() 中作为参数传入的值。
值
字符串。
示例
js
const docType = document.implementation.createDocumentType(
"svg",
"",
"http://www.w3.org/2000/svg",
);
console.log(docType.systemId); // Displays "http://www.w3.org/2000/svg"
规范
| 规范 |
|---|
| DOM # dom-documenttype-systemid |
浏览器兼容性
加载中…