Click to See Complete Forum and Search --> : Server Side AJAX question


ZeroFear
05-08-2006, 10:15 PM
since ajax is event driven from the client side, can a server broadcast to several clients when updates happen, not when the user causes an event?

gargkapil
05-09-2006, 05:05 AM
That is exactly what I want to implement in case of database updates...however I would imagine that the xmlhttprequest would be generated ina timely fashion using a timer or something...i doubt without calling the send method of the xmlhttprequest, if at all the client can automatically receive updates from the server...unless there is a server side technology which does that..

gavacho
06-03-2006, 08:42 PM
No. Ajax is not capable of "pushing" data to the client without first receiving a request from the client. Pushing can be simulated by having the client periodically poll the server for updates, but this is bandwidth and server resource intensive.

gargkapil
06-05-2006, 05:58 AM
very true! I was just able to simulate autorefesh using setTimer along with xmlhttpRequest. Gavacho (or anyone else who knows about this)-could you point out any references where I can get more information about bandwidth restriction. I cant find any article or references which provides enough information on the bandwidth restriction? We are going to implementing this sample code which I wrote as a component for autorefreshing the webpages on our product. But we would definately want to get all the pros and cons for the same for strong specification and proof of concept.

inchl
11-20-2006, 04:15 AM
Hi,

I apply a technique called serverside-blocked-calls (server-side AJAX) in my MVC-framework. See demos on my website: http://www.inchl.nl

Kind regards,

Stephan Smetsers