note 34207 deleted from function.scandir by aidan
| From: | aidan@php.net | Date: | Fri, 02 Jul 2004 06:08:51 +0000 |
| Subject: | note 34207 deleted from function.scandir by aidan | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-72308@lists.php.net to get a copy of this message | ||
Note Submitter: willem@overflow.nl
----
For users who doens't have the PHP5 support yet, this function works fine:
function scandir($dirstr) {
// php.net/scandir (PHP5)
$files = array();
$fh = opendir($dirstr);
while (false !== ($filename = readdir($fh))) {
array_push($files, $filename);
}
closedir($fh);
return $files;
}