You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Kevin Cadieux <kc...@gmail.com> on 2006/06/25 06:31:31 UTC

[users@httpd] Comet problem

Greetings everyone,

I recently started working on a project that involves instant messaging
through a web page. I thought it would be convenient for the server to push
the incoming messages to the user's browser as soon as they are sent. That
is why I started experimenting with Comet in order to make these server-sent
notifications possible. For testing purposes, I developed a simple web
application that waits on the web server for a URL to load. I made the
browser wait for the URL by loading a PHP file through AJAX. The php file
sleeps till the URL is available. The url is entered manually through anoter
web page. As soon as it is submitted,  it is outputted by the PHP file to
the browser. The browser then loads the URL.

At first I thought that I successfully found out how to use the Comet
technique. That was before I found out that I couldn't make multiple
requests to wait for a URL at the same time from the same computer using the
Firefox browser. Suppose I open 3 browser windows and load my web
application that waits for a URL in all of them. After I submit a URL, it is
not sent to all of them simultaneously. The web server first sends the
response to the first client, then to the second and to the third. I don't
know why it only does this with Firefox... Could it have anything to do with
the Apache web server and the way firefox makes the request?


Thank you,


Kevin

Re: [users@httpd] Comet problem

Posted by Issac Goldstand <ma...@beamartyr.net>.
Possibly PHP with auto-session starting is causing the serial responses...

See http://php.net/session-write-close

  Issac

Kevin Cadieux wrote:
> Greetings everyone,
> 
> I recently started working on a project that involves instant messaging
> through a web page. I thought it would be convenient for the server to
> push the incoming messages to the user's browser as soon as they are
> sent. That is why I started experimenting with Comet in order to make
> these server-sent notifications possible. For testing purposes, I
> developed a simple web application that waits on the web server for a
> URL to load. I made the browser wait for the URL by loading a PHP file
> through AJAX. The php file sleeps till the URL is available. The url is
> entered manually through anoter web page. As soon as it is submitted, 
> it is outputted by the PHP file to the browser. The browser then loads
> the URL.
> 
> At first I thought that I successfully found out how to use the Comet
> technique. That was before I found out that I couldn't make multiple
> requests to wait for a URL at the same time from the same computer using
> the Firefox browser. Suppose I open 3 browser windows and load my web
> application that waits for a URL in all of them. After I submit a URL,
> it is not sent to all of them simultaneously. The web server first sends
> the response to the first client, then to the second and to the third. I
> don't know why it only does this with Firefox... Could it have anything
> to do with the Apache web server and the way firefox makes the request?
> 
> 
> Thank you,
> 
> 
> Kevin

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org