Code:
<adresar>
<osoba>
<ime>ime1</ime>
<prezime>prezime1</prezime>
</osoba>
<osoba>
<ime>ime2</ime>
<prezime>prezime2</prezime>
</osoba>
</adresar>
AS skripta
Code:
osobaXml = new XML();
osobaXml.ignoreWhite = true;
osobaXml.onLoad = function(success) {
if (success) {
osobaItem = this.firstChild.childNodes; /broj osoba u xml dokumentu izlistati sa length kao array
ImeOsobe = this.firstChild.childnodes[0].childNodes[0].ChildNodes[0];
prezimeOsobe = this.firstChild.childnodes[0].childNodes[0].ChildNodes[1];
}
}
osobaXml.load("osobe.xml");
Ovo ti je osnova za rasckanjivanje xml dokumenta. Logika je jednostavna, samo treba prelistati manual (help) za vecu upotrebljivost xml u flash.
I am alpha and omega, I am the first and the last, I am the begining and the end...