NYCPHP Meetup

NYPHP.org

[nycphp-talk] Please wait, processing, message technique

Cliff Hirsch cliff at pinestream.com
Fri Jul 13 06:20:31 EDT 2007


On 7/12/07 10:22 PM, "Brent Baisley" <brenttech at gmail.com> wrote:

> I think you can rely on Javascript being present and enabled, with the all the
> web 2.0 stuff out there it just about has to be.
> 
> When I needed to run something long, I've run it in the background using the
> exec command. If you have command line php enabled, this could be just another
> php script. In that script you could use pcntl_fork to speed things up even
> more (multiprocessing). 
> I would then periodically call a script to check on the progress. Or the user
> could surf and do other things and then come back the page, at which time a
> check would be performed. O'Reilly sort of works this way when you want to
> create a PDF of  a book chapter.
> 
> If you use exec, you need to make sure it disconnects itself from the php
> process. As I recall you need to run it in the background (&) and send output
> to /dev/null. I forget if you need to do nohup also. You could get a bunch of
> things going at once, credit card payment and pi calcs.
> 
Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.nyphp.org/pipermail/talk/attachments/20070713/a3d985eb/attachment.html>


More information about the talk mailing list