1: 2: 3: 4: 5: 6: 7: 8: 9: 10:
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; }