December 1999
Intermediate to advanced
992 pages
22h 3m
English
In flat files, data binding works much the same way as it does with the any recordset. The following code will produce a result almost identical to that shown in Figure 21.3. (It just leaves off the headings.)
<xml id="cats" src="cats.xml"></xml> <table datasrc="#cats" border="1"> <tr> <td><span datafld="name"></span></td> <td><span datafld="age"></span></td> <td><span datafld="color"></span></td> </tr> </table>
Note how the element name is used to bind the data to the HTML element, and how the content of the xml element is treated as the value of the field.
We can bind to input text boxes and all the other elements in the same way. Things get much more complicated, however, when the XML file is not flat. What happens when ...
Read now
Unlock full access