-
I have a swf file that reads in an xml file to populate a dynamic text box. In the standalone version of the .swf, everything works GREAT! However, when I embed flash into a browser, and try to display the .swf file, the flash comes up with no data.
Has anyone experienced this problem where the xml data is failing to load? I even have the xml file in the same directory as the swf. And placed a few test items in the action script. I know it attempts to load the xml, but never succeeds.
Any help would be GREATLY appreciated.
-
Senior Member
The first thing to check is that the XML is loading correctly off the server. Use a browser to load the XML and check that it is being loaded in correctly.
As you have the files in the same directory you should not have any security problems. You are referencing the XML file as a relative path eg XML.Load(myxml.xml) don't specify the whole path. When I have done this it has worked nicely on the file system & the browser.
One final thing to check, make sure you have the right flash player installed all but the latest browsers have flash 4 by default. Right click (ctrl on the mac) on the flash player and check the about box.
Thanks
Luke
-
I have the same problem
I am wondering what you are talking about with security? I am having the same problem. I have a stock ticker that goes out and gets the latest information from NASDAQ in XML. It is then supposed to take that information and display it. When I run it locally, it works fine. But when I run it off the server, it doesn't work anymore. When I try it locally from the server it runs fine. I downloaded a copy to my yahoo breifcase to see if it was the ports on the server and it doesn't work there either. You can view the problem at http://briefcase.yahoo.com/dwashin/Work/xml.swf
Any help would of course be appreciated
-
Senior Member
Yep you definately hit the security issue.
Have a look at page 127-128 of the ActionScript Reference Guide. It has all the details of the XML and HTML security that is contained in flash.
I currently have a solution for getting PHP to mirror the XML from another server, hopefully in the coming days I will have perl & ASP solutions! This is the PHP solution:
< ?php
// get a web page into a string
echo join ('', file ('http://p.moreover.com/cgi-local/page?c=Developer%20news&o=xml'));
? >
Thanks
Luke
-
>Have a look at page 127-128 of the ActionScript Reference Guide.
Well, DUH! Now I need to figure out how to get the information from NASDAQ using an Apple script I guess. Thanks for the PHP information though. It will be useful when we upgrade to OS X Server sometime in the not to distant future...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|