编辑您的代码:
查看结果:
<html> <head> <script type="text/javascript" src="../example/xdom/loadxmldoc.js"> </script> </head> <body> <script type="text/javascript"> xmlDoc=loadXMLDoc("../example/xdom/books_comment.xml"); x=xmlDoc.getElementsByTagName("book")[0].childNodes; for (i=0;i<x.length;i++) { if (x[i].nodeType==8) { //Process only comment nodes document.write(x[i].data); document.write("<br />"); } } </script> </body> </html>
查看结果:
系统帮助
|
给我留言
|
收藏本站
Copyright © 2005-2008
www.cnn84.com
All Rights Reserved Ver:2.0
桂公网安备45122402000102号
CNN84网是公益性便民网站,是为了给大家的日常生活查询及提供最快捷的出行指南
夜深了!要注意身体呀! CNN84希望所有朋友都能做个好梦!