Trying to get my head around this.
Here is my xml
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<clients>
<client>
<company>Client Name One</company>
<image>01.jpg</image>
<image>02.jpg</image>
<image>03.jpg</image>
</client>
<client>
<company>Client Name Two</company>
<image>01.jpg</image>
<image>02.jpg</image>
<image>03.jpg</image>
</client>
</clients>
Here is my actionscript
function loadXML(loaded) {
if (loaded) {
company = new Array();
image = new Array();
xmlNode = this.firstChild
total = xmlNode.childNodes.length
for (i=0; i<total; i++) {
company* = xmlNode.childNodes*.childNodes[0].firstChild.nodeValue;
image* = xmlNode.childNodes*.childNodes[1].firstChild.nodeValue;
}
firstClient();
} else {
content = "file not loaded!";
}
}
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load("client.xml");
firstClient = function() {
vCompany = company[1];
vImage = image[1];
}
Basically what I need is for the xml to show a few images for a particular client, but even if i manually edit the array values I cannot get it to work.
Can anyone help me out with this. I am looking at the slideshow and xml tutorial, but the setup is very different to my requirements.
Any help would be good.
Cheers
Trev