Skip site navigation (1) Skip section navigation (2)

Re: Spaawn another process

From: "Michael Upchurch" <mike(at)partner2partner(dot)net>
To: "YC Nyon" <ycnyon(at)pd(dot)jaring(dot)my>, pgsql-php(at)postgresql(dot)org
Subject: Re: Spaawn another process
Date: 2002-11-06 20:00:29
Message-ID: courier.3DC974DD.0001526F@p2p.partner2partner.net (view raw or flat)
Thread:
Lists: pgsql-php
"YC Nyon" wrote:
>In my PHP page, I need to run a external program to insert map data into
>Postgresql. However, the process is very slow (can be 10 mins). How do I
>return a webpage telling the user that the process is running and permits
>the user to browse the other parts of the web application.
>My idea is to run the "exec();" after the </html> tag. Would that be the
>way?

Use register_shutdown_function() to run a function which exec's the
command. This turns lose of the browser while the command executes. Of
course, you will lose the ability to poll the status of the command unless
you build this into your function.

-- 
Michael J. Upchurch
Partner2Partner Communications, LLC

pgsql-php by date

Next:From: Andrew McMillanDate: 2002-11-06 20:05:08
Subject: Re: Handling timestampz datatype
Previous:From: Andrew McMillanDate: 2002-11-06 19:58:49
Subject: Re: Handling timestampz datatype

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group