Hi ! I have one question that is it possible to implement AJAX PUSH with PHP ? I want to deliever some content to my users who are currently online with request from the client side request.. Is it possible? If yes, do guide me.. thanks, Bhullarz
Let me make my question again... AS I am unable to edit my own post, I am posting it again. Hi ! I have one question that is it possible to implement AJAX PUSH with PHP ? I want to deliever some content to my users who are currently online without request from the client side request.. Is it possible? If yes, do guide me.. thanks, Bhullarz
Even this question is not answered yet. So, let me answer it on my ow. Read Amazon Web Services. they are into such services for past 5 years. It is called Reverse Ajax / Comet / Ajax Push which can be implemented using PHP. Using this technique, we do not require action from client side to activate a script on the server. Server scripts can keep track of new data and can deliver to client without client's request.
as i understand, the logic is something like the client has an opened connection to the server and picks up the resopnse from the server when available and in reverse AJAX instead of the client checking for messages, the server send the message to client at once and i think putting up a timeout or an interval will make a continous conenction but hope anyother have a better idea
I don't know of anyway to have the serve push data to the browser without using ajax. The server would have to request a browser reload if it were currently possible. Do your friends not have javascript turned on or something? You'd need some sort of file chaining or turn off the timeout because once a page loads the execution of that script stops and would not be able to "push" any thing. The whole purpose of ajax is so that you can make a request without reloading the page. Its not meant to work in reverse and have a script send data to the browser, let alone without a refresh. Server side is for the business logic and data manipulation while the client is for the display and they were not built with having the server being able to just send data that the client didn't request(this prevents servers from just sending viruses from scripts without a link being clicked or an infected page being loaded).