js获取本地xml var xdoc = new ActiveXObject("Microsoft.XMLDOM"); xdoc.async="true"; xdoc.load('例10-6.XML'); nodes=xdoc.documentElement.childNodes; var txt=" "+" "+nodes.item(0).text+" "+nodes.item(1).text+" "+" "; document.write(txt);