I have seen this question before and found this example in http://www.zeitoun.net/articles/comet_and_php/start which is really great and clear. However, it uses javascript.
My question is, are there any plugins, functions or something that would help me to implement PHP comet with jQuery easily? Because given example requires lots of javascript code.
And by the way, I want to use it on Apache. Is it possible?
If you are only doing long polling then jQuery will work fine. However, jQuery does not expose a readyState === 3 event, so there is no built in way to get data as it is streaming if that is the direction you want to go.
[Edit] Here is the bug, #1172
And it looks like they added the functionality in 1.5, using a Prefilter
So yes, you can do all the comet stuff with jQuery now :)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With