Re: disconnect



On Thu, 28 Apr 2005 23:21:07 +0200, "ste" <str@xxxxxxxxxxx> wrote:

>Is it possible to know when a client disconnect physically from apache
>server

That would be at the end of the script, or possibly earlier.

http://uk2.php.net/manual/en/features.connection-handling.php
http://uk2.php.net/register_shutdown_function

... or just at the bottom of the file.

Or possibly a bit later due to HTTP/1.1 keepalives, it depends what you're
after.

>(in another words when the clients closes its browser)

Closing the browser has nothing to do with closing the connection to Apache.

>I'm doing a php extension under win32/apache and I don't "see" any message
>I can trap to detect that kind of state...

There is no reliable way to do this; it's not how HTTP works.

There are possibly Javascript methods to do this, try comp.lang.javascript for
more details.

--
Andy Hassall / <andy@xxxxxxxxxxx> / <http://www.andyh.co.uk>
<http://www.andyhsoftware.co.uk/space> Space: disk usage analysis tool
.



Relevant Pages

  • Re: fopen url wrapper
    ... When I attempt to access a script on a certain Win2K3 server that ... I don't think your browser is of any concern. ... Your script cannot get the remote contents. ... resaved and restarted Apache just to be sure. ...
    (comp.lang.php)
  • Re: Script termination and reload after 5 minutes
    ... Strange problem on a lamp installation: A script runs longer than 5 minutes and sends no output to the browser until it is finished. ... no apache log entry about that. ...
    (comp.lang.php)
  • Script termination and reload after 5 minutes
    ... Strange problem on a lamp installation: A script runs longer than 5 minutes and sends no output to the browser until it is finished. ... no apache log entry about that. ...
    (comp.lang.php)
  • mod_python apache configuration issues
    ... It's a Mandrake 10 linux box, and apache/mod_python are installed from rpms. ... The apache config files contained the following before my modifications: ... I get a popup from the browser because it doesn't know how to handle ... open it in a text editor I'd see the entire mptest.py script. ...
    (comp.lang.python)
  • Re: mod_python apache configuration issues
    ... > The apache config files contained the following before my modifications: ... > I get a popup from the browser because it doesn't know how to handle ... > open it in a text editor I'd see the entire mptest.py script. ... > I'm not a python developer, but have been working with Linux and Apache ...
    (comp.lang.python)