stancox on 10/21/09
Last Edited at 10/21/09 05:05am
<?phpif ($dir = @opendir(getcwd())) { while(($file = readdir($dir)) !== false) { if(is_dir($file)&&$file!=="."&&$file!=="..") { $array[] =$file." (dir)"; } elseif(is_file($file)) { $array[] =$file." (file)"; } } closedir($dir);}print_r($array);?>
Report this snippet Tweet
Comment:
You need to login to post a comment.