Spry data sets
In the Spry framework, a data set requests information from a file or web service, and stores the response for display by other Spry components.
The data set is Spry’s implementation of the Ajax technique.
About Spry data sets
After you create a data set, you can specify how you want to display the data on a web page by using Spry regions.
Spry creates each kind of data set slightly differently. For example, when you create an XML data set, it is important that you specify the correct XPath when creating the data set. When you create an HTML data set, you don’t use XPath, but rather an ID that identifies the HTML element that contains the data to extract. Regardless of the type of data set you create, Spry attributes and data references work the same way.
Spry Data Sets and XML
Keep the following important points in mind when using XML as a data source:
- XML nodes are case sensitive.
- Valid XML displays properly in browsers. If it works properly in a browser, it should work properly for Spry.
- You must wrap special characters in CDATA.
- You must deliver XML documents as text/xml or application/xml documents.
- The encoding declared in the XML source file should be the same as the encoding for the HTML page.
- The XML source must reside on the same domain as the Spry page.
- The XML can come from an XML file or a dynamic page that generates XML.
About XML @ adobe.com
Example: data set and repeat list
Advanced example: Accordion with Spry data set
The link below shows an advanced Spry example, using an Accordion to display a Spry data set.