Groups | Blog | Home
all groups > flash actionscript > august 2007 >

flash actionscript : Preload External Jpgs



805collective
8/23/2007 7:37:38 PM
What is the easiest way to preload external jpgs? The client wants to update
these frequently so they should be external, but I want them to show up
instantly like the rest of the site once the preloading is done.

Any advice? I had thought about loading them into the preloader (at 0%
alpha), so that they'd be loaded into the cache during preload, so that when
the home page comes up, they'd be all ready to go? But if it's a different
instance of the movieclip, will it reload the jpg? Or any time i use that
external jpg in the flash file will it already be in the cache?

Thanks. I've heard a few different things and would love your advice.

Jeremy
GWD
8/23/2007 8:45:09 PM
There are two different things here. pre-caching (I don't know what else to
call it) and pre-loading.

It is possible to pre-cache files off the same server. If you load into
different instances then it should get it from the cache, so yes that would
speed things up. But... results are dependent on an unknown factor: the user's
cache settings. If its set to never cache you could end up downloading 'to the
cache' and just wasting bandwidth.
You can read about that approach here.

http://www.actionscript.com/Article/tabid/54/ArticleID/Preloading-Files-into-the
-Browser-s-Cache/Default.aspx

Then there's the regular preload approach where you preload into movieclips
(perhaps with ._visible=false or 0% ._alpha etc).
You can find a lot of info relevant to that here:

http://www.quip.net/blog/2007/flash/actionscript-20/tracking-multiple-files-part
1

http://www.quip.net/blog/2007/flash/actionscript-20/tracking-multiple-files-part
2


AddThis Social Bookmark Button