XML DOM xmlStandalone 属性
XML DOM Document 对象的 xmlStandalone 属性设置或返回文档是否为 standalone
语法
documentObject.xmlStandalone
范例
下面的范例显示 XML 编码、standalone 属性和文档的 XML 版本
xmlDoc=loadXMLDoc("/static/media/dom/books.xml"); document.write("XML encoding: " + xmlDoc.xmlEncoding); document.write("<br>"); document.write("XML standalone: " + xmlDoc.xmlStandalone); document.write("<br>"); document.write("XML version: " + xmlDoc.xmlVersion); document.write("<br>"); document.write("Encoding used when parsing: " + xmlDoc.inputEncoding);