Php,xml and Flash [multiple holders]
Hi
A few days ago I posted a discussion related to php,xml and Flash. I want to display my xml in flash. I got help in doing so. I now have a problem getting the xml data that is contained in my array to be displayed on different holder movie clips.
This is my code. I have been trying different configuration of the code but with no luck.
var urls:Array = [];
var index:Number;
var index1:Number;
var xml:XML = new XML();
xml.ignoreWhite = true;
xml.onLoad = parseXML;
xml.load("content.php");
function parseXML(){
for(var i:Number=0;i<this.firstChild.childNodes.length;i++){
urls.push(this.firstChild.childNodes.firstChild.nodeValue);
}
index=0;
index1=1;
startyourappF();
}
function startyourappF(){
this.onEnterFrame = preloadA;
holder.loadMovie(urls[index]);
//this is me trying to get the second item in the url in a another movie clip holder.
holder1.loadMovie(urls[index1]);
}
function preloadA(){
if(holder.getBytesLoaded()>50&&holder.getBytesLoaded()>=holder.getByte sTotal()){
delete this.onEnterFrame;
holder._width = 260.0;
holder._height = 96.0;
}
//this should be resizing for the second holder.
if(holder1.getBytesLoaded()>50&&holder1.getBytesLoaded()>=holder1.getB ytesTotal()){
delete this.onEnterFrame;
holder1._width = 260.0;
holder1._height = 96.0;
}
}
The code sucessfully loads the first image to holder but is unable to load the second url to holder1 and others I want to add. I spend the whole night trying out different configurations of the code but with no success.
I hope you can help me. All I need is more than one image loaded from the urls array variable into multiple other holder variables.
Hope you can help.
cheers>>