ajax - How do I display real-time information to the user? -
i need show new comments user in real-time (similar youtube's live comments system no auto-adding).
maybe need use pools asyn controller handle requests , show if user clicks on "show more 10 comments".
or, example, similar stackoverflow's alert new inbox messages.
it looks you're wanting 'push' data user in real-time.
previously might have been done bit of 'hack' solution known long-polling
with long polling, client requests information server in way similar normal polling; however, if server not have information available client, instead of sending empty response, server holds request , waits information become available (or suitable timeout event), after complete response sent client.
however might want html5 world of websockets. i'd recommend reading on signalr , following tutorials (watch pluralsight videos).
asp.net signalr new library asp.net developers simplifies process of adding real-time web functionality applications.
there lot of information available on topic.
Comments
Post a Comment