<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Caching, Updating, and Versioning SWFs</title>
	<atom:link href="http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/</link>
	<description></description>
	<lastBuildDate>Tue, 25 Mar 2008 13:45:30 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Kenny Bunch</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-38</link>
		<dc:creator>Kenny Bunch</dc:creator>
		<pubDate>Tue, 08 Feb 2005 20:02:20 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-38</guid>
		<description>Aran,

I haven&#039;t had to deal with Flash 5 in a while, but you should never put variant parameters (those that change a lot) as query strings on the actual load of your app. I updated my post with a way of doing this with a proxy swf that gets around the issue.</description>
		<content:encoded><![CDATA[<p>Aran,</p>
<p>I haven&#8217;t had to deal with Flash 5 in a while, but you should never put variant parameters (those that change a lot) as query strings on the actual load of your app. I updated my post with a way of doing this with a proxy swf that gets around the issue.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Aran Rhee</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-37</link>
		<dc:creator>Aran Rhee</dc:creator>
		<pubDate>Fri, 04 Feb 2005 02:39:05 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-37</guid>
		<description>Just a little reminder about flashVars which wasn&#039;t covered.

It is only available on flash v6+ So for anyone still having to do a flash 5 project ( for whatever reason), you have to use the query string method. If I know I am targeting the to the widest audience, I include flashVars as well as a querystring in the object/embed tags.</description>
		<content:encoded><![CDATA[<p>Just a little reminder about flashVars which wasn&#8217;t covered.</p>
<p>It is only available on flash v6+ So for anyone still having to do a flash 5 project ( for whatever reason), you have to use the query string method. If I know I am targeting the to the widest audience, I include flashVars as well as a querystring in the object/embed tags.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kenny Bunch</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-45</link>
		<dc:creator>Kenny Bunch</dc:creator>
		<pubDate>Mon, 10 Jan 2005 19:53:50 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-45</guid>
		<description>Guy,

Right. In the main movie if you are loading assets you have to have a versioning scheme or something to force updates of assets as they face all the same issues. I use a unique ID on all data requests internal to the base swf to ensure clean requests when I need to. During internal dev and testing, unique requests are fine. Versioning and caching becomes more of an issue in a high profile production environment. For example, on CNN.com I may have an app that I put out there, but 3 months later they add features to it. I use the versioning system to enforce it caches, but it updates on clients when I add the new release with its versioning. I couldn&#039;t have it not cache because I need the efficiency of the base caching. Of course, all this I&#039;m describing depends on what you are doing and who you are serving to.

PS. why the Math.random()*100 on your call? new Date().getTime() returns a unique millisecond # which should be sufficient, what&#039;s the extra expression for?</description>
		<content:encoded><![CDATA[<p>Guy,</p>
<p>Right. In the main movie if you are loading assets you have to have a versioning scheme or something to force updates of assets as they face all the same issues. I use a unique ID on all data requests internal to the base swf to ensure clean requests when I need to. During internal dev and testing, unique requests are fine. Versioning and caching becomes more of an issue in a high profile production environment. For example, on CNN.com I may have an app that I put out there, but 3 months later they add features to it. I use the versioning system to enforce it caches, but it updates on clients when I add the new release with its versioning. I couldn&#8217;t have it not cache because I need the efficiency of the base caching. Of course, all this I&#8217;m describing depends on what you are doing and who you are serving to.</p>
<p>PS. why the Math.random()*100 on your call? new Date().getTime() returns a unique millisecond # which should be sufficient, what&#8217;s the extra expression for?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Richard Leggett</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-44</link>
		<dc:creator>Richard Leggett</dc:creator>
		<pubDate>Mon, 10 Jan 2005 19:52:12 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-44</guid>
		<description>Very cool stuff, haven&#039;t tried syncing with CVS yet.  I use the &quot;?version=X.XX&quot; when it comes to the object/embed tags for the main movie, but when it comes to loading in sub movies. I decided to put together a simple little utility class to help:

http://www.richardleggett.co.uk/downloads/flash/CacheKiller/CacheKiller.as

So I use it like this:

var subs_array = [&quot;one.swf&quot;, &quot;two.swf&quot;];
if (CacheKiller.isOnline())  CacheKiller.fixArray(subs_array);

Seems to work quite well, but it does suffer from the &quot;always having to reload content&quot; issue, however I usually find the main site/navigation (which IS version controlled) is the heftiest in terms of kB&#039;s anyway, so no big issue :)</description>
		<content:encoded><![CDATA[<p>Very cool stuff, haven&#8217;t tried syncing with CVS yet.  I use the &#8220;?version=X.XX&#8221; when it comes to the object/embed tags for the main movie, but when it comes to loading in sub movies. I decided to put together a simple little utility class to help:</p>
<p><a href="http://www.richardleggett.co.uk/downloads/flash/CacheKiller/CacheKiller.as" rel="nofollow">http://www.richardleggett.co.uk/downloads/flash/CacheKiller/CacheKiller.as</a></p>
<p>So I use it like this:</p>
<p>var subs_array = ["one.swf", "two.swf"];<br />
if (CacheKiller.isOnline())  CacheKiller.fixArray(subs_array);</p>
<p>Seems to work quite well, but it does suffer from the &#8220;always having to reload content&#8221; issue, however I usually find the main site/navigation (which IS version controlled) is the heftiest in terms of kB&#8217;s anyway, so no big issue <img src='http://www.kennybunch.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Guy Watson</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-43</link>
		<dc:creator>Guy Watson</dc:creator>
		<pubDate>Mon, 10 Jan 2005 19:16:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-43</guid>
		<description>You also have to remember that the page that contains the .swf will still be cached (even if you add various no-cache headers on the server-side) and any .swfs loaded into the main movie will also be cached unless you also add a random query string:

&lt;code&gt;
my_mc.loadMovie(&quot;myMovie.swf?rn=&quot;+new Date().getTime()+(Math.random()*100))
&lt;/code&gt;

Kenny, very true, but during development this is not an issue. Its also an issue that is merley a shortcoming if you actually want to ensure that people always see the latest content/application/flash movie on your website. You have to weigh up the pro&#039;s and the con&#039;s and decide which way to go.

Also remember that this can be done with any type of content, including movies, sounds and images both inside of flash and in html.</description>
		<content:encoded><![CDATA[<p>You also have to remember that the page that contains the .swf will still be cached (even if you add various no-cache headers on the server-side) and any .swfs loaded into the main movie will also be cached unless you also add a random query string:</p>
<p><code><br />
my_mc.loadMovie("myMovie.swf?rn="+new Date().getTime()+(Math.random()*100))<br />
</code></p>
<p>Kenny, very true, but during development this is not an issue. Its also an issue that is merley a shortcoming if you actually want to ensure that people always see the latest content/application/flash movie on your website. You have to weigh up the pro&#8217;s and the con&#8217;s and decide which way to go.</p>
<p>Also remember that this can be done with any type of content, including movies, sounds and images both inside of flash and in html.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kenny Bunch</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-42</link>
		<dc:creator>Kenny Bunch</dc:creator>
		<pubDate>Mon, 10 Jan 2005 18:31:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-42</guid>
		<description>Casey,

Exactly. Mod date is a smart method to automate to. I sync mine with the CVS version just so I can look and have a visual indicator to know which version is out there. It&#039;s a personal preference, but you definitely get the point.</description>
		<content:encoded><![CDATA[<p>Casey,</p>
<p>Exactly. Mod date is a smart method to automate to. I sync mine with the CVS version just so I can look and have a visual indicator to know which version is out there. It&#8217;s a personal preference, but you definitely get the point.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: casey corcoran</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-41</link>
		<dc:creator>casey corcoran</dc:creator>
		<pubDate>Mon, 10 Jan 2005 18:21:42 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-41</guid>
		<description>I was reading this and just thought, &quot;I could probably just use some server side script to get the mod date of the swf and append it to the query string...&quot;

That way you wouldnt have to worry about versioning your swf by hand, good idea?</description>
		<content:encoded><![CDATA[<p>I was reading this and just thought, &#8220;I could probably just use some server side script to get the mod date of the swf and append it to the query string&#8230;&#8221;</p>
<p>That way you wouldnt have to worry about versioning your swf by hand, good idea?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kenny Bunch</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-40</link>
		<dc:creator>Kenny Bunch</dc:creator>
		<pubDate>Mon, 10 Jan 2005 17:38:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-40</guid>
		<description>Guy,

Good point about writing out the object/embed with js. I actually have a custom js class that I use to write out all my .swfs. However, be careful with using a unique # everytime in the embed code. The reason I say this is server and client efficiency. For the server, if you are having to serve the same file everytime and noone is caching it, and you have tons of concurrent requests your server is going to have to do more especially if the files are large. More importantly, (and I forgot to mention in my post, which I&#039;ll probably edit in) if the client has a slow connection, say 56k and the file is 150kb which I consider to be large they will have to wait to download it each time they visit your site. On the other hand if it is cached on a version basis then they can use a cached version of the base .swf and only load ondemand needed items in the .swf. Make sense?</description>
		<content:encoded><![CDATA[<p>Guy,</p>
<p>Good point about writing out the object/embed with js. I actually have a custom js class that I use to write out all my .swfs. However, be careful with using a unique # everytime in the embed code. The reason I say this is server and client efficiency. For the server, if you are having to serve the same file everytime and noone is caching it, and you have tons of concurrent requests your server is going to have to do more especially if the files are large. More importantly, (and I forgot to mention in my post, which I&#8217;ll probably edit in) if the client has a slow connection, say 56k and the file is 150kb which I consider to be large they will have to wait to download it each time they visit your site. On the other hand if it is cached on a version basis then they can use a cached version of the base .swf and only load ondemand needed items in the .swf. Make sense?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Guy Watson</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-39</link>
		<dc:creator>Guy Watson</dc:creator>
		<pubDate>Mon, 10 Jan 2005 17:25:55 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-39</guid>
		<description>Cheers Kenny.

It&#039;s good practice, to write out your object/embed tags with javascript during development, and append a unique string to the query string to ensure visitors always see the latest release. Especially when you have testers, checking the application while your building it.

&lt;code&gt;&quot;mymovie.swf?rn=&quot;+new Date().getTime()+(Math.random()*100)

*/

its it highly improbable that the resulting query string will ever be the same twice, even if the user changes their system time due to the extra addition of a random number at the end

*/
&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>Cheers Kenny.</p>
<p>It&#8217;s good practice, to write out your object/embed tags with javascript during development, and append a unique string to the query string to ensure visitors always see the latest release. Especially when you have testers, checking the application while your building it.</p>
<p><code>"mymovie.swf?rn="+new Date().getTime()+(Math.random()*100)</p>
<p>*/</p>
<p>its it highly improbable that the resulting query string will ever be the same twice, even if the user changes their system time due to the extra addition of a random number at the end</p>
<p>*/<br />
</code></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mason</title>
		<link>http://www.kennybunch.com/blog/2005/01/caching-and-updating-swfs/comment-page-1/#comment-36</link>
		<dc:creator>mason</dc:creator>
		<pubDate>Mon, 10 Jan 2005 16:25:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.kennybunch.com/blog/?p=10#comment-36</guid>
		<description>Nice write-up there Mr. Bunch.  Caching is defiantly a huge issue in Flash development.  So much so that recently its been one of the selling points / benefits people have been talking about for doing Flex development.  --which for me, I don&#039;t quite buy... (in more ways than one)  Calling the version from the embed tag is a very easy and elegant way to go.  Its not a solve all but its a good start.</description>
		<content:encoded><![CDATA[<p>Nice write-up there Mr. Bunch.  Caching is defiantly a huge issue in Flash development.  So much so that recently its been one of the selling points / benefits people have been talking about for doing Flex development.  &#8211;which for me, I don&#8217;t quite buy&#8230; (in more ways than one)  Calling the version from the embed tag is a very easy and elegant way to go.  Its not a solve all but its a good start.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Dynamic Page Served (once) in 0.591 seconds -->

