Re: [flexcoders] Fwd: problem with relative assets path
Use Modules? http://livedocs.adobe.com/flex/201/html/modular_083_2.html Check the docs for Module and ModuleManager. regards, Muzak - Original Message - From: "Bart Wttewaall" <[EMAIL PROTECTED]> To: Sent: Thursday, December 27, 2007 12:16 AM Subject: [flexcoders] Fwd: problem with relative assets path > *bump* (yeah, I know.. shameless!) > > -- Forwarded message -- > From: Bart Wttewaall <[EMAIL PROTECTED]> > Date: 23 dec. 2007 21:57 > Subject: problem with relative assets path > To: flexcoders@yahoogroups.com > > Hi list, > > I'm building a big Cairngorm application that consists of a GUI that loads > various swf's as pages. The path to these pages is "assets". > > One of the loaded pages is "products.swf ", a standalone Cairngorm > application that loads assets. It's built in its own folder and locates the > assets under the following path: "assets/products". The problem is that when > I load this page into the GUI it can't find the assets anymore. > > After lots of tests I found out that "products.swf" needs its assets to be a > path relative to itself, not relative to the swf it is loaded in! I've > always learned that a swf needs its assets path set relative to the swf it > is loaded in. It gets even more strange: it needs a copy of its assets, > nested in the already available assets folder in order to work or it simply > cannot access them. Removing the original assets and just using the deeper > nested assets doesn't work either. > > Here is a (simplified) image of the folder trees in the setup that seems to > work: > http://download.mediamonkey.nl/double-asset-paths.png > > So my question is, how is this possible? And what can be done to make sure > that I only have one folder with assets that all loaded swf's can get access > to? > > Thanks in advance, > Bart > -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/flexcoders/join (Yahoo! ID required) <*> To change settings via email: mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
RE: [flexcoders] Fwd: problem with relative assets path
Clearly you are talking about assets loaded at run-time, since embedded assets are baked in. I have taken to passing a full assets url into any application via flashvars and accessing that via the application.parameters associative array. This prevents path issues, and let me have different asset sets for different installs without changing the swf. Of course, I have to prepend the assets url variable to any asset reference. Tracy From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Bart Wttewaall Sent: Wednesday, December 26, 2007 6:17 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Fwd: problem with relative assets path *bump* (yeah, I know.. shameless!) -- Forwarded message -- From: Bart Wttewaall <[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> > Date: 23 dec. 2007 21:57 Subject: problem with relative assets path To: flexcoders@yahoogroups.com <mailto:flexcoders@yahoogroups.com> Hi list, I'm building a big Cairngorm application that consists of a GUI that loads various swf's as pages. The path to these pages is "assets". One of the loaded pages is "products.swf ", a standalone Cairngorm application that loads assets. It's built in its own folder and locates the assets under the following path: "assets/products". The problem is that when I load this page into the GUI it can't find the assets anymore. After lots of tests I found out that "products.swf" needs its assets to be a path relative to itself, not relative to the swf it is loaded in! I've always learned that a swf needs its assets path set relative to the swf it is loaded in. It gets even more strange: it needs a copy of its assets, nested in the already available assets folder in order to work or it simply cannot access them. Removing the original assets and just using the deeper nested assets doesn't work either. Here is a (simplified) image of the folder trees in the setup that seems to work: http://download.mediamonkey.nl/double-asset-paths.png <http://download.mediamonkey.nl/double-asset-paths.png> So my question is, how is this possible? And what can be done to make sure that I only have one folder with assets that all loaded swf's can get access to? Thanks in advance, Bart
[flexcoders] Fwd: problem with relative assets path
*bump* (yeah, I know.. shameless!) -- Forwarded message -- From: Bart Wttewaall <[EMAIL PROTECTED]> Date: 23 dec. 2007 21:57 Subject: problem with relative assets path To: flexcoders@yahoogroups.com Hi list, I'm building a big Cairngorm application that consists of a GUI that loads various swf's as pages. The path to these pages is "assets". One of the loaded pages is "products.swf ", a standalone Cairngorm application that loads assets. It's built in its own folder and locates the assets under the following path: "assets/products". The problem is that when I load this page into the GUI it can't find the assets anymore. After lots of tests I found out that "products.swf" needs its assets to be a path relative to itself, not relative to the swf it is loaded in! I've always learned that a swf needs its assets path set relative to the swf it is loaded in. It gets even more strange: it needs a copy of its assets, nested in the already available assets folder in order to work or it simply cannot access them. Removing the original assets and just using the deeper nested assets doesn't work either. Here is a (simplified) image of the folder trees in the setup that seems to work: http://download.mediamonkey.nl/double-asset-paths.png So my question is, how is this possible? And what can be done to make sure that I only have one folder with assets that all loaded swf's can get access to? Thanks in advance, Bart