I used to be rather good in js, and I think i found your solution.
In AC_OETags.js, the function AC_GetArgs, change the following (line 200):
case "src":
case "movie":
args[i+1] = AC_AddExtension(args[i+1], ext);
ret.embedAttrs["src"] = args[i+1];
ret.params[srcParamName] = args[i+1];
break;
to this
case "src":
case "movie":
args[i+1] = AC_AddExtension(args[i+1], ext) + '?build=' + (new
Date()).getTime();
ret.embedAttrs["src"] = args[i+1];
ret.params[srcParamName] = args[i+1];
break;
The new Date() creates a date-object of the current moment and
getTime() return the milliseconds for that date since 1/1/1970 (GMT)
Hope it works,
--jeetee
--- In [email protected], Darren Houle <[EMAIL PROTECTED]> wrote:
>
>
> I'm trying to stop the client's browser from caching my flex app swf
so that each time they call the html wrapper they get the latest swf.
>
> I've found some suggestions out there for accomplishing this, and I
think adding the "myapp.swf?build=12341234" (some timestamp) solution
looks cleanest, but I was wondering...
>
> Has anyone modified their index.template.html wrapper so that each
time you compile your app it auto-generates and appends that random
(or time based) number like this? Anyone know if there's an example
out there I can look at? It would be nice if this was automatic and I
didn't have to implant a new number in the wrapper each time by hand.
>
> Thanks
> Darren
>