flash configuration file

Tag: flash Author: hsliuyl Date: 2009-07-21

I am creating a reusable Flash swf for displaying xml data in a treemap, which will be highly configurable. I am considering requiring an xml settings file at the root, akin to a .NET web.config appSettings section. Default values for the settings will exist in a AS class file, which will be overridden by the xml config file. They can be then overridden again by the flashvars parameter.

Is there are more standardized way of doing this, or am I taking the correct approach?

Best Answer

That's a pretty standard approach, and one I use quite often.

I do have to ask though, are you referring to the web root, or simply the location of the HTML file that hosts the SWF? I would recommend against having to have the file at the web root, but having it at some relative path based on the HTML that holds the SWF is perfectly fine.