chuleto1 has asked for the wisdom of the Perl Monks concerning the following question:
Any suggestions@return_files = readDirectory($directory); foreach(@return_files) { next if ($_ eq "." || $_ eq ".."); ####################### #How can a tell between files and directories? ######################## print OUT "<ul> <li id=\"foldheader\">$_</li>"; print OUT "</ul>"; } sub readDirectory { opendir DIR, $directory; @files = readdir(DIR); return @files; closedir(DIR); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Diff between file and directory
by allolex (Curate) on Aug 25, 2003 at 17:39 UTC | |
by Grygonos (Chaplain) on Aug 25, 2003 at 19:28 UTC | |
|
Re: Diff between file and directory
by bear0053 (Hermit) on Aug 25, 2003 at 17:34 UTC | |
by allolex (Curate) on Aug 25, 2003 at 17:42 UTC | |
|
Re: Diff between file and directory
by Fletch (Bishop) on Aug 25, 2003 at 17:37 UTC | |
|
Re: Diff between file and directory
by vek (Prior) on Aug 26, 2003 at 04:11 UTC |