ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/reports/php/shared/iutils.inc.php
Revision: 1.2
Committed: Tue Mar 13 19:08:16 2001 UTC (23 years, 8 months ago) by pjm2
Branch: MAIN
CVS Tags: PROJECT_COMPLETION
Changes since 1.1: +1 -1 lines
Log Message:
Silly mistake... somebody shoot me

File Contents

# Content
1 <?
2
3 # return an array of subdirectories from a directory.
4 function getdirArray($dir='./',$sort='asort') {
5 global $dir_file_count;
6 if ( is_dir($dir) ) {
7 $fd = @opendir($dir);
8 while ( ($part = @readdir($fd)) == TRUE ) {
9 clearstatcache();
10 if ($part != "." && $part != "..") {
11 $dir_array[] = $part;
12 }
13 }
14 if($fd == TRUE) {
15 closedir($fd);
16 }
17 if (is_array($dir_array)) {
18 $sort($dir_array);
19 $dir_file_count = count($dir_array);
20 Return $dir_array;
21 } else {
22 Return FALSE;
23 }
24 } else {
25 Return FALSE;
26 }
27 }
28
29 ?>