|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2000-10-17 12:37 UTC] seth at the-hub dot com
i wrote a script with something like the following:
exec("touch somefile") or die("couldnt create file!");
and it worked fine in php 4.0.1
but when i upgraded to 4.0.2 the exec kept dying even though there was no error.
when i upgraded to 4.0.3 it still did not work.
i've also tried replacing exec() with a system() call and that did not help.
note: permissions have not changed on any dirs so that's not the problem, and exec doesn't return any errors (or any output at all for that matter) into the error array or anywhere else
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Tue Jan 27 22:00:01 2026 UTC |
This inteded function of exec. string exec (string command [, string array [, int return_var]]) You need to test return_val which will be the error condition. ex. exec("touch hi",,$err); if ($err) die("Could not create file"); -jason