ID:               19658
 Updated by:       [EMAIL PROTECTED]
 Reported By:      [EMAIL PROTECTED]
-Status:           Open
+Status:           Bogus
 Bug Type:         Directory function related
 Operating System: Windows 2000
 PHP Version:      4.2.0
 New Comment:

Thank you for taking the time to report a problem with PHP.
Unfortunately you are not using a current version of PHP -- 
the problem might already be fixed. Please download a new
PHP version from http://www.php.net/downloads.php

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.


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

[2002-09-29 08:22:20] [EMAIL PROTECTED]

This script works OK:
if ($handle = @opendir('.')) {
   while (false !== ($file = readdir($handle))) {  
           if (is_dir($file)) { 
                   echo "Is directory $file <BR>"; 
                   }
                   else Print "Is file $file <BR>";
   }
   closedir($handle); 
}
When I replace "." with i.e. "C:\webpages\test" (this is the directory
where I run the script from) it also works fine.
But when I try the read a directory which is not in the same directory
as the script i.e. "C:\webpages" than it displays that there are only
files. So reading a directory lower or higher that the direcory where
you are running a script from gives a wrong output.

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


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

Reply via email to