04.02.2013 Views

Spry User Guide - Support - Adobe

Spry User Guide - Support - Adobe

Spry User Guide - Support - Adobe

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

var dsPhotos = new <strong>Spry</strong>.Data.XMLDataSet("/photos.php?galleryid=2000",<br />

"/gallery/photos/photo");<br />

<br />

The following code represents the data as it arrives in text format:<br />

<br />

John Doe<br />

john@doe.com<br />

<br />

<br />

<br />

<br />

<br />

<br />

The following example represents the data as it arrives in DOM-tree format.<br />

The data set then uses the XPath specified in the constructor to navigate the XML DOM tree to find the particular<br />

nodes that represent the data you are interested in.<br />

The following code shows data selected with the /gallery/photos/photo XPath, in bold:<br />

<br />

John Doe<br />

john@doe.com<br />

<br />

<br />

<br />

<br />

<br />

<br />

SPRY<br />

<strong>User</strong> <strong>Guide</strong><br />

94

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!