[PHP-DEV] PHP 4.0 Bug #8674: invallid filetype() results (affects isdir() )

2001-01-12 Thread yavo
From: [EMAIL PROTECTED] Operating system: redhat 6.2 PHP version: 4.0.4 PHP Bug Type: Filesystem function related Bug description: invallid filetype() results (affects isdir() ) im using php for shell scripting in redhat 6.2. compiled with './configure'

RE: [PHP-DEV] PHP 4.0 Bug #8674: invallid filetype() results (affects isdir() )

2001-01-12 Thread Sean R. Bright
Thats because you need to pass a valid filename to filetype(). PHP is trying to find $file in its current directory even if $dir is /usr/local/not/phps/current/dir. I have fixed your example below. (Note that this still won't work if the last character of $dir is not a '/', so append one where