Re: Command Line PHP Advice
| From: | Nirmalya Lahiri | Date: | Mon, 30 Jan 2006 07:43:16 +0000 |
| Subject: | Re: Command Line PHP Advice | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-229445@lists.php.net to get a copy of this message | ||
Angelo,
I am very happy after knowing that it is working. :)
--Nirmalya
Angelo Christou <christou44@yahoo.com> wrote:
Hello Nirmalya,
Thank you for your response. With the help of your reply, I've now got it working! :)
Ang.
Nirmalya Lahiri <nirmalyalahiri@yahoo.com> wrote: Hi,
you can do this by using unix command 'for'. Please apply the
command written below......& reply me your experiment result.
for filename in
ls *.txt;do ./edit.php $filename var1 var2;done
--Nirmalya
--- Angelo Christou wrote:
> Hello List
> I would like some advice from PHP users regarding PHP and the
> command line. I have a PHP script that does a whole bunch of stuff
> to a file on my intranet.
>
> ./edit.php filename var1 var2
>
> Everything works fine but I need to run it on a list of files -
>
> ./edit.php invoice00212.txt var1 var2
> ./edit.php invoice00213.txt var1 var2
> ./edit.php invoice00214.txt var1 var2
>
---------------------------------
Bring words and photos together (easily) with
PhotoMail - it's free and works with your Yahoo! Mail.
---------------------------------
Bring words and photos together (easily) with
PhotoMail - it's free and works with your Yahoo! Mail.