RE: [PHP] php-cli - Controlling external programs
[snip] Bah, not the answer I was looking for...I really wanted to use PHP and I have most of what I wanted accomplished. Thanks for the tip, I will investigate. [/snip] http://us3.php.net/features.commandline If you use -a for your command line script the script will run interactively example: php -a myscript.php or if you want to use a bash line at the head of your script #!/usr/local/bin/php -a (dependent upon the location of php) HTH -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php-cli - Controlling external programs
--- Mike Maltese [EMAIL PROTECTED] wrote: I'm writing a script to be run from the command line. ... How can I get the signal from tar that the tape needs to be changed? It sounds like you are wanting to write an interactive shell script. If this is the case (e.g., I didn't misunderstand), you should probably use expect instead of PHP. Hope that helps. Chris = Become a better Web developer with the HTTP Developer's Handbook http://httphandbook.org/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php-cli - Controlling external programs
Bah, not the answer I was looking for...I really wanted to use PHP and I have most of what I wanted accomplished. Thanks for the tip, I will investigate. Chris Shiflett [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] --- Mike Maltese [EMAIL PROTECTED] wrote: I'm writing a script to be run from the command line. ... How can I get the signal from tar that the tape needs to be changed? It sounds like you are wanting to write an interactive shell script. If this is the case (e.g., I didn't misunderstand), you should probably use expect instead of PHP. Hope that helps. Chris = Become a better Web developer with the HTTP Developer's Handbook http://httphandbook.org/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php-cli - Controlling external programs
Hi, Thursday, July 31, 2003, 1:53:50 PM, you wrote: MM I'm writing a script to be run from the command line. It controls my DAT MM autoloader (tape changer) and runs tar so that I can automate my backups. MM With the -M option, tar will prompt for a new tape when the current tape is MM full. How can I get the signal from tar that the tape needs to be changed? MM Is there another way to interact with external programs other than, exec, MM backticks, etc.? I'm running 4.3.2-cli on FreeBSD with POSIX and pcntl MM functions enabled. MM Thanks, MM Mike Maybe this will help http://sourceforge.net/projects/mtx/ -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php