You are here: Need help w/ system, exec, or proc_open « PHP Language « IT news, forums, messages
Need help w/ system, exec, or proc_open

Posted by DC on 08/26/05 18:51

Im not even sure which on i should be using, but hear is my situation. From within my php script I need to run another program and put it in
the background... I thought that doing exec("/usr/local/bin/someapp &") would do it, but it dosn't...


This program should be througn in the background (it has an endless loop and dosn't want user imput or anything).
after this program has started, my php script needs to wait for 5 seconds, and continue running.

at the end of the script I need to kill the program i originally started...
Can anyone help me out with this???


here is my perl equivilent:

system("myapp \&");
sleep 5;

.... ..... ....

system("killall -9 myapp");


Thank you

 

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

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