I have made a rather nice livechat application in php/mysql/ajax
I have integrated it onto my website inside members profiles. If they are online the image appears where other members can click to send a livechat request
That dumps a row in a mysql database. Ever 2 minutes, on the other persons homepage, ajax checks the database for requests. If it finds one, it starts the livechat between the two people. Great!
Well, I want to go one better. If its livechat, having a 2 minute delay between requests is a real pain. I know web technology hasn't quite caught up with that yet so are limited, but Im wonderin what the best way to go about it is
I have heard something about 'Server Push' or 'PHP Sockets'
Basically, with msn, when a message is sent it literally is sent straight from them to you. The other persons msn client doesnt query a central server for messages every second. I know its not web language, but is this acheivable using any web languages.
If not, what would you guys suggest
Sure I could make the AJAX refresh every 30 seconds rather than 2 minutes, but sometimes there are 1000 people online. I dont want to blow my server up!
Cheers !