Forum Moderators: open

Message Too Old, No Replies

message indikator

         

namalo

8:57 am on Sep 8, 2005 (gmt 0)



Hi! This is my first topic here. I hope some one can help me with my problem.

For a web-community I am doing a gustbook and message notifier in flash. It's quite simple, the flash file loads vars from a php file which sends a "0" when there are no messages and a "1" when there are new ones.

when recieved a 1 it jumps to frame 10 and loops a couple of times and returns to frame 1 again to do the check again.

The problem is that this only works on some web-browsers. Mostly you have to open a new webbrowser-window so the flash file "updates". And the whole point of the notifier is lost.

The actionscript I have used is the following:


data = new LoadVars();
myurl="http://mysite/eb.php?uid=" + _root.uid; //uid from a flashvar
data.load(myurl);
data.onLoad = function(){
if(data.mail=="1")gotoAndPlay(10);
else gotoAndplay(5);
}

Please tell me if something looks funny or can be done much better.