...

View Full Version : loading external image - AS2



sitNsmile
03-09-2012, 07:04 PM
function processXMLData(success)
{
if (success)
{
//var banner = new MovieClipLoader();
var rootNode = this.firstChild;
var img = getValue(findNode(rootNode, "image"));
var url = getValue(findNode(rootNode, "link"));

// this isnt displaying the image in the swf
b1.loadMovie(img,1);

trace(img);
trace(url);
}
else
{
trace("error");
}
}

var xmlData=new XML();
xmlData.ignoreWhite=true;
xmlData.load("http://mydomain.com/file.xml");
xmlData.onLoad=processXMLData;



Trying to figure why this doesnt work. However when i replace "img" with a real http url it works fine, but when i load the image url off xml, it doesnt render. any ideas?



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum