Avatar

Level 2

I like the idea of loading in config properties from an XML file, but I am still looking for a while to externalize the server information without

requiring any changes to config files.  That is, I am trying to keep it such that clients, etc. can just drop in the WAR file and go.

I found this snippet of code which returns the name of the server from which the SWF file was served:

URLUtil.getServerName(FlexGlobals.topLevelApplication.url)

There are always way to get the port number and determine if it was SSL or not.  With this I feel I can hard-code the port 80 (443) and the context and voila -- I have a completely solution for run-time configuration of channel sets without compiling against services-config.xml or hard coding the server URL anywhere.

I'll report back if I doesn't work....