Hi Everyone,
I recently coded a 'chatbox' for my site. I made it 'live' so that if someone posts a message, it shows up without you refreshing the page. To do this, I use: setInterval ( "myfunction()", 5000 ); to call an ajax function which checks if there are any new posts. The thing is, my webserver tells me that I have the max number of processes running (all calling this ajax function which checks if there are new posts). The ajax function is getting called every 5 seconds by tons of people even if there are no new posts... Can I make it so that the server updates all of the peoples browsers when someone someone posts a message, instead?
Thanks a lot!
Cheers,
Crispin
Shoutbox woes :(
Moderator: General Moderators
-
Crispin_Java
- Forum Newbie
- Posts: 8
- Joined: Thu Feb 05, 2009 2:34 pm
Re: Shoutbox woes :(
Wow, I must be getting pretty good a php when I am having totally original problems
