I got this far, is this ok?
$dir = '/staff/lad/public_html/SWT';
opendir(DIR, $dir) or die "Cannot open directory";
foreach $entry (readdir DIR)
{
print "$entry\n"
}
closedir(DIR);
"Dan Muey" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
com...
There was a post about exactly this not too long ago. I'd look in the
archive.
It used File::Slurp to read the directories and print an html list.
That way it's easy, fast , prortable, you don't' have to worry about parsing
the output of 'ls', etcc.
DMuey
> Hi guys,
>
> Need a perl CGI script that will print to a web page the
> contents of a directory specified in the program. Basically
> i need the perl program to simply call the unix "ls"
> function, not sure how to encorporate this into my script
> though, any ideas?
>
>
> Cheers
>
> matt.
>
>
>
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]