Skip to main content
Inspiring
June 23, 2008
Question

xml on server not loading consistently

  • June 23, 2008
  • 1 reply
  • 284 views
I have a project in which I'm loading an xml file of about 70kb in size. When testing, I'm finding that sometimes it loads properly, and sometime the user needs to click the browser's Refresh button before the xml will load.
I'm using what I think is fairly common code:
-------
myData.onLoad = function(success) {
if (success) {
//code here parses the xml
}
myData.load("myxmlfile.xml");
---------
The file always plays perfectly fine when played directly off of my PC, but I receive the inconsistent results when the files are loaded to the server. I assume that the xml file isn't being loaded properly or quickly enough all the time, but I can't figure out what the issuemight be. Any help would be appreciated. Thanks!
Bill
This topic has been closed for replies.

1 reply

Inspiring
June 23, 2008
>>and sometime the user needs to click the browser's Refresh button before
>>the xml will load.

Hi Bill, the code you have looks ok. Is the movie doing the loading of the
XML, being loaded by another movie - a preloader perhaps? If that's the case
you probably need to delay the load call until the movie is fully loaded.


--
Dave -
www.offroadfire.com
Head Developer
http://www.blurredistinction.com
Adobe Community Expert
http://www.adobe.com/communities/experts/