Re: command line are -c doesn't work on win2k?
| From: | DL Neil | Date: | Fri, 18 Jan 2002 10:50:52 +0000 |
| Subject: | Re: command line are -c doesn't work on win2k? | ||
| References: | 1 | Groups: | php.general php.windows |
| Request: | Send a blank email to php-general+get-81061@lists.php.net to get a copy of this message | ||
Jeff,
The following batch files works for me (WinNTWS 4.0 SP6a):-
cd c:\program files\php
php.exe -q c:\.path.\w.php >>c:\.path.\webute.log
NB the first line reflects my PHP config - your mileage may vary!
Of course the other possibility is to add the PHP folder into the PATH environment variable...
Regards,
=dn
----- Original Message -----
From: "Jeff D. Hamann" <jeff_hamann@hamanndonald.com>
To: <>; <php-windows@lists.php.net>
Sent: 18 January 2002 07:00
Subject: [PHP-WIN] command line are -c doesn't work on win2k?
> I've been trying to figure out what was wrong with my script...
>
> <?
> mail("who@where.what", "Subject", "command line mail() test");
> ?>
>
> from the command line,
>
> php mail_test.php
>
> and getting,
>
> X-Powered-By: PHP/4.0.6
> Content-type: text/html
>
> attempting to deliver the mail<br>
> <b>Warning</b>: Unknown error in <b>mail_test.php</b> on line
> <b>3</b><br>
>
> Then I found a solution at http://bugs.php.net/bug.php?id=6742
> ,
>
> [22 Nov 2000 5:21am] sniper@php.net
> After a few emails this really got solved.
> Adding -c/path/to/phpini/ (command line)
> was the solution.
>
> --Jani
> but, when I tried it,
> php -c c:\php mail_test.php,
> Again, the results were,
> X-Powered-By: PHP/4.0.6Content-type: text/html
>
> attempting to deliver the mail
> <br><b>Warning</b>: Unknown error in <b>mail_test.php</b> on
> line
> <b>3</b><br>
>
>
> So, I tried a gazillion permitations on -c, -c /php, -c
> c:/php -c:\php\php.ini, etc, etc, etc, to no avail...
>
> I finally moved the script into the same dir as php.exe and it worked fine.
> The problem is that I need to run the script from the "normal" path and not
> from c:\php...
>
> Does the -c switch actually work? How can I run this script from another
> dir? Is this a bug?
>
> Thanks,
> Jeff.
>
>
> --
> Jeff D. Hamann
> Hamann, Donald & Associates, Inc.
> PO Box 1421
> Corvallis, Oregon USA 97339-1421
> Bus. 541-753-7333
> Cell. 541-740-5988
> jeff_hamann@hamanndonald.com
> www.hamanndonald.com
>
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-windows-unsubscribe@lists.php.net
> For additional commands, e-mail: php-windows-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>
>