PDA

View Full Version : Displaying current the Server Time (hour:minute)


mandalavillage
07-15-2007, 03:49 AM
Hi everyone:

I have developed a code in PHP that displays the servertime and then it passes in a variable to flash using the "echo" command in PHP and "LoadVars" in flash .. well... everything works fine, except by:

It only loads quite well ONCE, because everytime I come inside the same page it keeps the value of the time which is located in the CACHE memory...

Is there anyway I can kill time to time the value that is loaded on memory ? so it calls every certain time the PHP process in prder to obatin the current time ?? I will appreciat your answer,

Thanks in advance,

Sw. Jiten.

LOLFlash
07-16-2007, 01:56 AM
Develop script in Flash that displays current time of client and sed it to server as variables

atomic
07-16-2007, 02:44 AM
Just add a random number to the loading script of your php file, so that the cached file is not reused.

mandalavillage
07-16-2007, 06:26 AM
I already added a random numer, but then , it does not laod anything ! even the time is not being displayed... here is my code.. please help... :

var a = new LoadVars();
a.load("timelimaperu.php");
a.onLoad = function() {
mitexto.text = this.mitexto;
};

Flash Gordon
07-16-2007, 06:32 AM
var a = new LoadVars();
a.load("timelimaperu.php?killcache=" + Math.random() * 9000);
a.onLoad = function() {
mitexto.text = this.mitexto;
};