Hi,
i am trying to build a xml menu. my xml scheme looks like this:
<images>
<pic>
<cat></cat>
<image></image>
<titlename></titlename>
<description></description>
</pic>
</images>
i am trying to use cat to sort the menu into columns. for example if cat == web _x = 300. i have not made the menu yet but i just need to know how i would go about using cat to position the menu links.
heres my code
function loadXML(loaded) {
if (loaded) {
xmlNode = this.firstChild;
cat = [];
image = [];
titlename = [];
description = [];
/*bodytext = [];*/
total = xmlNode.childNodes.length;
for (i=0; i<total; i++) {
cat* = xmlNode.childNodes*.childNodes[0].firstChild.nodeValue;
image* = xmlNode.childNodes*.childNodes[1].firstChild.nodeValue;
titlename* = xmlNode.childNodes*.childNodes[2].firstChild.nodeValue;
description* = xmlNode.childNodes*.childNodes[3].firstChild.nodeValue;
//trace (titlename*)
trace (cat*)
}
firstImage();
} else {
content = "file not loaded!";
}
}
many thanks,
G