[PHP-DEV] Bug #237 Updated: misleading filetype() info From: Bug Database (php-dev <email protected>)
Date: 05/01/98

ID: 237
Updated by: zeev
Reported By: sbedberg <email protected>
Status: Suspended
Bug Type: Other
Assigned To:
Comments:

Please let us know whether this indeed solved
your problem.

---

PHP probably isn't finding the files because you're not giving it complete paths to the files (but is finding . and .. because they're always there).

You want to do:

<?php $dir = "F:\\!web"); $dh = opendir($dir); while ($fname = readdir($fh)) { echo "$fname (" . filetype($dir. "\\" . $fname). ")<BR>"; } closdir($dh); ?>

Full Bug description available at: http://ca.php.net/bugs.php3?id=237