You are here: Re: exec() in the background « All PHP « IT news, forums, messages
Re: exec() in the background

Posted by Redfox05 on 02/15/06 20:57

shortbackandsides.no@spam.hairdresser.net wrote:
<snip>
> I'd like a way of reconnecting to a background script via a browser
> ... anyone?

This is a complete guess, as ive done similar stuff, but not exactly as
below.
How about putting in something that checks for the presence of a
certain file. maybe /dir/stop.txt or anything.
And in the while loop, have this if() statement that checks for the
existence, and when you create this file, the background script finds
this file and then does a die() command, or even better, if you need to
make the script do more stuff, put the new php commands in this
stop.txt and use an inlude within the if() statement to carry them out.

If you try this method, let me know if it works.
I have not yet put php scripts into background proccesses, so if you
know how to do this, let me know.

Only done cron things upto now to run the script every so often, plus
running php script from command line and interacting with on the spot
user input, which is cool. Even got it interacting with mysql so i
could get info like i was using a normal program.

Anyways, ramble over, let me know if this helps.

Russell

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация