Name: Anonymous 2009-12-10 18:52
I've been looking online and can only find example of listing items inside a folder. The only think I want to do is list folders inside a folder. How should I go about doing this?
if(-d $filename){
#isdir
print $filename;
}
#!/usr/bin/perl -Tw
use strict;
use CGI;
use CGI::Carp qw(fatalsToBrowser);
print "Content-type: text/html\n\n";
my @files = <*>;
for (@files) {
my $filename = $_;
if (-d $filename) {
#isdir
print $filename;
}
}