Thursday 6 October 2011

Flash cache issue: load a unique swf every time

When building apps/games which require regular updates then you will come across the problem with the swf being cached and you cannot see the changes.

Solution
provide the Flash with a unique id as a variable.

Example

var myIdentifier = Math.round(Math.random()*10000);


swfobject.embedSWF("Application.swf?id="+myIdentifier, ...)

No comments:

Post a Comment