Hi guys
I am trying to make a portfolio site with different picture galleries. Every gallery is supposed to work the same way, but the pictures will be different(ofcourse). The problem is that I can’t make it work unless I make an individual swf file for each gallery. With my actionscript knowledge I am therefore quite limited…
I need to be able to make a function so that every button opens up the same movieclip but with at different xml file attached to it, can anyone help.
This is what I have so far, but getting it on a button is harder than I thought.
function loadXML(loaded) {
if (loaded) {
xmlNode = this.firstChild;
image = [];
description = [];
infotext = [];
total = xmlNode.childNodes.length;
for (i=0; i<total; i++) {
image* = xmlNode.childNodes*.childNodes[0].firstChild.nodeValue;
description* = xmlNode.childNodes*.childNodes[1].firstChild.nodeValue;
infotext* = xmlNode.childNodes*.childNodes[2].firstChild.nodeValue;
}
firstImage();
} else {
content = "file not loaded!";
}
}
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load("content/xml_folder/row_a.xml");
All help is greatly appreciated…
-B