Thanks Glen - that seems to be just what I was after. Cheers
Paul -----Original Message----- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Glen Pike Sent: 02 April 2009 09:15 To: Flash Coders List Subject: Re: [Flashcoders] Detecting if authoring mode (Flash 8 AS2) Hi, I have used the "_root.url" variable before to detect whether it is an "http" or a "file" based one and done caching based on that. Glen Paul Steven wrote: > Is there a property or function to detect if a Flash movie is being tested > in authoring mode or live on the web? > > Basically I have added a random variable to my xml file when loading it to > prevent caching. > > The following works in both authoring and when live > > myXML.load("xml/homeFlashContent.xml"); > > Whereas the following including the cache busting code doesn't work when > tested within Flash IDE. > > my_Date = new Date(); > > myXML.load("xml/homeFlashContent.xml?"+my_Date.getUTCSeconds()); > > I would therefore like to have an if statement something like > > If (boolAuthoringMode == true) { > > myXML.load("xml/homeFlashContent.xml"); > > } else { > > myXML.load("xml/homeFlashContent.xml?"+my_Date.getUTCSeconds()); > > } > > > If there are any better solutions please let me know. > > Thanks > > Paul > > _______________________________________________ > Flashcoders mailing list > Flashcoders@chattyfig.figleaf.com > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > > _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders