This isnt exactly what your looking for, Im sure of it, but it works for me
in the past. If you have a page that does something like email 1000
shareholders about a new press release, this takes some time. You dont need
to sit here for 30min to wait for the page to finnish.
<?
//-email.php-
exec("php -q email_press.php &");
?>
<?
//-email_press.php-
for($c = 0; $c < 1000; $c++)
{
mail(...);
}
?>
send your web client to email.php and that will call email_press.php wich is
now running in the backgound. not at all like forking a process, but it
works.
--
Chris Lee
Mediawaveonline.com
[EMAIL PROTECTED]
"Nicklas af Ekenstam" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hi!
>
> Is there some way (perhaps using a multi threaded httpd?) that I can get
> php to fork processes?
> I.e. I'd like to have a script which prints something to the clients web
> browser and terminates that http connection, but keeps going in the
> background doing other processing not related to the client and, if
> necessary, pipes that output to /dev/null.
>
> - Nille
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]