Why don't you try to use mkdir() instead of shell commands?

http://us2.php.net/manual/en/function.mkdir.php

-M

-----Original Message-----
From: Sævar Öfjörð [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 15, 2003 8:19 PM
To: [EMAIL PROTECTED]
Subject: [PHP] executing a shell command within a function


Hi,

I’m coding a function that will create a set of directories using execution
of shell commands within the function. Then the function saves different
sizes of images in each directory. Later in the function I open one of these
directories to list the content in them. The problem is that the directoris
don’t exist when the function is trying to list the content in them. When I
execute the function again with exactly the same parameters there is no
problem, then the directories exist!

I’m thinking that the shell commands are somehow set in some kind of buffer
or queue and are not executed until the rest of the php code is executed?
Could this be true? If anyone has anything to say on this I’d appreciate it.

BTW I'm using RH8.0 and PHP 4.2.2
 
Kveðja,
Sævar Öfjörð
[EMAIL PROTECTED]
þetta reddast - hönnunarlausnir
www.reddast.is



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php





--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to