News for hackers. Stuff that matters.
Re:An Introduction to Web Sockets by pornel on Sunday July 17, 2011 @08:20AM (#2773159)
For non-games usually Server-Sent Events (http://dev.w3.org/html5/eventsource/) may be simpler to use:

• it's pure HTTP, message format is dead simple ("data: payload\n\n")

• browser handles network failures and reconnections automatically.

• browsers can share same stream URL between windows

His use-cases with to-do app and analytics were good fits for SSE.

Re:An Introduction to Web Sockets by camwest on Sunday July 17, 2011 @04:28PM (#2774114)
Once Firefox supports SSE I agree that it would be easier to implement in many use cases. Although it doesn't have the same sort of fallback mechanisms available to it that WebSockets have (ActionScript sockets).

Here is some additional information about it that I found at stackoverflow: http://stackoverflow.com/questions/5195452/websockets-vs-ser...

Re:An Introduction to Web Sockets by pornel on Monday July 18, 2011 @05:32AM (#2775651)
You can fall back to XHR with long polling — the stream is trivial to parse.
Re:An Introduction to Web Sockets by zeroxsys on Sunday July 17, 2011 @12:18PM (#2773548)
I'll check that out, thanks!