ID: 12220
Updated by: cynic
Reported By: [EMAIL PROTECTED]
Old Status: Bogus
Status: Open
Old Bug Type: Unknown/Other Function
Bug Type: Feature/Change Request
Operating System: windows 98
PHP Version: 4.0.6
New Comment:

Hartmut Holzgraefe:
you have to check for file existance with file_exists() before you
try to probe for its filetype


I think it'd be useful if the is_<type> functions in the FS category did that for the 
user, so moving to feature request.

I don't know enough about the underlying C stuff, but I don't think is_<type> checking 
the existence of the file/dir/whatever would be more expensive, would it?

Previous Comments:
------------------------------------------------------------------------

[2001-07-18 01:37:06] [EMAIL PROTECTED]

Sorry! This is *not* a support forum.

Subscribe to the PHP General mailing list ([EMAIL PROTECTED]). 

Visit http://php.net/support.php for more information.

------------------------------------------------------------------------

[2001-07-18 01:17:47] [EMAIL PROTECTED]

the problem is.... 
i want to check a directory ... 
09 <? chdir("d:/temp") 
10 $dir="username"; 
11 if(is_dir($dir)) 
12 { 
13 //code 
14 }else 
15 {mkdir($dir,0700);} ?> 
php return a error...NO SUCH DIRECTORY OR FILE ON LINE 11 ... 
my goals is to check is there a directory name "username" if there are not a directory 
name "username" i want to create it ..can anybody help me how i can solve this problem 



thanx before that...... 


------------------------------------------------------------------------



Edit this bug report at http://bugs.php.net/?id=12220&edit=1


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to