Search code examples
asp.netjquerylivepolling

Live connection between server and client in a web page


How do I implement a real time updating /live html streaming method in applications like FriendFeed, Stackoverflow, Blip.fm ?

Is it done using a jQuery/Ajax request from client to server every X seconds? (FriendFeed is like every 1 second) or there is another technique?


Solution

  • There are a lot of techniques and ideas that started to came up with the need of a more interactive web.. You can find some reference here at stackoverflow

    You can research about Comet, Polling and javascript, etc.

    What SO does is to check the activity by using an ajax POST request to https://stackoverflow.com/posts/2977129/answer-activity-heartbeat for example in this question page. The request returns whether there was some activity happened or not, and an action is taken accordingly.