spacer

Webref WebRef   Sitemap · Experts · Tools · Services · Newsletters · About i.com

home / experts / javascript / column104


Web Services, Part IX: Pattern-Based XML Node Selection

Developer News
Microsoft Shows Off Silverlight 4, IE9 Plans
Metasploit Expands Vulnerability Test Framework
HyperCard Reborn?

Context Definition - Part B

The fourth node of mydvd7.xml is where the data tree hangs. The name of the top-level child is sales (xmlDoc.childNodes[3].nodeName), from the sales tag:

<sales>
  .
  .
  .
</sales>

The sales node has two child nodes:

The summary node has five child nodes:

The summary's child nodes do not have any lower-level child nodes. The data node is the root of a much deeper tree, as it holds the actual data of the dvds. The data node has three child nodes, one for every month of the report:

Each month has five child nodes: one for its name and four for its four week proceeds. Here are the child nodes of January:

Similarly, here are the child nodes of February:

March's three child nodes are:

The name nodes have child nodes of their own, one per node. They hold the name's text property:


Next: How to select nodes

http://www.internet.com

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs

webref The latest from WebReference.com Browse >
Rolling Out Your Own HTML Application Version Control · HTML 5: Client-side Storage · Working with Ajax Server Extensions
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Wi-Fi Product Watch, November 2009 · Chip Market Recovering From '08 Collapse · Low-Cost Tools to Kickstart Your New Business


Produced by Yehuda Shiran and Tomer Shiran
All Rights Reserved. Legal Notices.
Created: February 25, 2002
Revised: February 25, 2002

URL: http://www.webreference.com/js/column104/3.html