We keep out URL's in an external XML file which is deployed on different environments. When app loads make a call to the Servlet and gets the URL's. The Servlet returns the configuration according to the environment that it is deployed on. HTH, C
________________________________ From: Nick Middleweek <n...@middleweek.co.uk> To: flexcoders@yahoogroups.com Sent: Thu, February 25, 2010 2:32:28 PM Subject: Re: [flexcoders] Strategies for switching between testing and deployment addresses Hey David, If you have a local DNS you could setup a subdomain for the production IP and edit your windows hosts file to override it to point locally... Tracy mentioned FlashVars, that's a real easy way. You've help me enough in the world of 4D so I'll ping something over if you need it... Cheers, Nick On 22 February 2010 02:00, David Adams <dpad...@gmail. com> wrote: > > > > > > > > > > > > > > > > >> > >> > >I've been writing some small programs that use HTTPService calls to >>fetch data from a back-end. During testing, I'm using 127.0.0.1 or an >>IP address on my subnet. When I deploy, I update the IP address in >>service definitions to the right external address and build the app. >>Or at least I mean to. It's all too easy to accidentally change the >>addresses for internal testing and then forget to switch them back >>before building. > >>Is there a best practice or simple strategy for putting the IP address >>somewhere outside of the source code that it can easily be edited >>without a rebuild? > >>Thanks for any advice. > > >