|
|
|
Forum Guru
      
участник
Last Login: 11.06.2003 13:19
Сообщ.: 70,
Visits: 771
|
|
Есть xml файл. Хочe его проанализировать и выдать в html. В чём ошибка? Жалутся на 14 строку...
<% Set myxml=Server.CreateObject("msxml") myxml.url = "http://www.rcb.ru/trades.xml" Set root=myxml.root %> <body bgcolor="white"> <p><center><hr width=80%>XML sample page <hr width=80%></center><p> <%parse root%> </body> <%function parse(root) i=0 if root.type=0 Then Response.Write ("<UL>Current tag is " & root.tagName & "parent is " & root.parent) elseif root.type = 1 Then Response.Write ("<LI>It is a text of " & root.parent.tagName & "element: <i>" & root.text & "</i></LI>") else Response.Write ("<br><br>Error") End if if root.children <> null Then Response.Write("It consist of " & root.children.length & " elements:") for i=0 to root.children.length parse(root.children.item(i)) Next else Response.Write("</UL>") End If End Function%>
|
|
|
|
|
Supreme Being
      
участник
Last Login: 12.02.2004 16:41
Сообщ.: 1 756,
Visits: 19 372
|
|
| попробуй Server.CreateObject("Msxml2.DOMDocument")
|
|
|
|