note 30053 added to function.system
| From: | cnoelker at softpearls dot de | Date: | Wed, 05 Mar 2003 12:13:11 +0000 |
| Subject: | note 30053 added to function.system | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-44871@lists.php.net to get a copy of this message | ||
Hi,
some tips for using a system()-call for batch files on a windows computer:
* Write the path to the executable with double back-slashes, like so:
C:\\path\\to\\prog.exe
* If you are refering to other pathes, e.g. as a parameter, one back-slash works fine.
* Do not use SET for declaring parameters - this does not work! Example:
SET PATH="C:\path\to\lib"
echo path is %PATH%
This works fine when started from the comand line, but when called from PHP, the variable is just
empty.
--
http://www.php.net/manual/en/function.system.php
http://master.php.net/manage/user-notes.php?action=edit+30053
http://master.php.net/manage/user-notes.php?action=delete+30053
http://master.php.net/manage/user-notes.php?action=reject+30053