jlizarraga
06-10-2008, 11:29 PM
First of all, thanks a bunch to those of you (especially Medyman) who helped me get me first Flash/XML project working a few weeks ago. It was a for a car dealership and you can see it here:
http://www.futurefordofconcord.com
Now I am doing a Fleet Vehicles site for the same guys, located here:
http://www.futurefordofconcord.com/fleet/
Notice that the Flash piece says "XML Car Data has failed to load. :(". Now view the very same swf directly:
http://www.futurefordofconcord.com/fleet/images/homepage.swf
Outside the bounds of the html page, it works just as intended.
Here's the AS2.0 loading the xml file:
//load homepage.xml
var carData:XML = new XML();
carData.ignoreWhite = true;
carData.onLoad = function(success) {
if (success) {
m1dtfV.text = "XML Car Data loaded successfully! :)";
parseCarData ();
} else {
m1dtfV.text = "XML Car Data has failed to load. :(";
}
};
carData.load("homepage.xml");
I have tried playing around with the location of the homepage.xml file (it is currently resting in the same /images/ directory as the swf itself) and have used both relative and absolute paths to point to the file, but the result is always the same: the file works on its own, but once embedded into the homepage it fails to load the XML.
That's what makes me think its a security issue, but I don't really get why its happening or how to fix this. Any tips greatly appreciated!
http://www.futurefordofconcord.com
Now I am doing a Fleet Vehicles site for the same guys, located here:
http://www.futurefordofconcord.com/fleet/
Notice that the Flash piece says "XML Car Data has failed to load. :(". Now view the very same swf directly:
http://www.futurefordofconcord.com/fleet/images/homepage.swf
Outside the bounds of the html page, it works just as intended.
Here's the AS2.0 loading the xml file:
//load homepage.xml
var carData:XML = new XML();
carData.ignoreWhite = true;
carData.onLoad = function(success) {
if (success) {
m1dtfV.text = "XML Car Data loaded successfully! :)";
parseCarData ();
} else {
m1dtfV.text = "XML Car Data has failed to load. :(";
}
};
carData.load("homepage.xml");
I have tried playing around with the location of the homepage.xml file (it is currently resting in the same /images/ directory as the swf itself) and have used both relative and absolute paths to point to the file, but the result is always the same: the file works on its own, but once embedded into the homepage it fails to load the XML.
That's what makes me think its a security issue, but I don't really get why its happening or how to fix this. Any tips greatly appreciated!