Тема: Html&xhtml
Показать сообщение отдельно

  #4  
Старый 03.02.2005, 17:59
Algol
Регистрация: 29.05.2002
Сообщений: 1,793
Провел на форуме:
2050916

Репутация: 0


По умолчанию

XML можно
Например так:
Код HTML:
This example uses the XML element to define a simple XML data island that can be embedded directly in an HTML page.

<XML ID="oMetaData">
  <METADATA>
     <AUTHOR>John Smith</AUTHOR>
     <GENERATOR>Visual Notepad</GENERATOR>
     <PAGETYPE>Reference</PAGETYPE>
     <ABSTRACT>Specifies a data island</ABSTRACT>
  </METADATA>
</XML>
This example uses the readyState property of the xml object to determine whether the XML data island is completely downloaded.

  if (oMetaData.readyState == "complete")
      window.alert ("The XML document is ready.");

This script example retrieves the text contained within the ABSTRACT field of the data island.

   var oNode = oMetaData.XMLDocument.selectSingleNode("METADATA/ABSTRACT");
   alert(oNode.text);
(C)MSDN