Cache Issues

Yep, it’s another question about cache issues.

Let me get down to it.

How would I incorporate this: Cache tut., with this one: [URL=http://www.kirupa.com/developer/mx2004/transitions.htm]Transitions Between External Files?

The script on the transitions tutorial is:[AS]
on (release) {

if (_root.currMovie == undefined) {

_root.currMovie = “main”;
container.loadMovie(“main.swf”);
} else if (_root.currMovie != “main”) {
if (container._currentframe >= container.midframe) {

_root.currMovie = “main”;
container.play();

}

}

}
[/AS]I think I may have an idea, but would like to hear it from someone else.

How would I add the script from the cache tutorial into this script?

Like this?


on (release) {
	if (_root.currMovie == undefined) {
		_root.currMovie = "main";
		myIdentifier = Math.round(Math.random()*1000000);
		container.loadMovie("main.swf?uniq="+myIdentifier);
	} else if (_root.currMovie != "main") {
		if (container._currentframe>=container.midframe) {
			_root.currMovie = "main";
			container.play();
		}
	}
}


Well that’s what I was thinking but wanted someone else to either confirm it or correct it. Thanks for your reply… anyone else want to add something to this?

Anyone? Anyone at all. :ne:

it’s correct, but I would use the date+time instead of a random number (more secure)