PDA

View Full Version : Ping? Cross-browser update? or how do you call it..



shab
3 Feb 2010, 1:47 AM
Basically i want to implement a method that updates all other browsers who opened my application. Example there are 10 users currently opening an inventory module, when I update some values to these inventory module, it will ping or automatically update all users who were opening the inventory module to reflect the new values without them having to invoke the refresh button to get the reflected changes.

Of course I could do this if I make the program to do database query every second but that is a waste of resources and bandwidth.

Is there such method where we could somehow

Lloyd K
3 Feb 2010, 2:11 AM
Look at the source for Etherpad, this uses COMET to update all users in near real time.

tobiu
3 Feb 2010, 2:12 AM
the terms are long-polling (pinging the server for updates) or server-push-technologies (keeping a connection alive). server-push is not natively supported in ext yet, since it is a client-only-library.

kind regards,
tobiu

shab
3 Feb 2010, 11:16 AM
thanks for shedding light on this guys. I'm off to reading a lot of stuffs. :D