in reply to File list by date
Something like this perhaps...
opendir(ROOT, $dir) || die "$!\n"; foreach (sort { -M $b <=> -M $a } readdir(ROOT) ) { print "$_\n"; }
Update: snax below quite rightly points out a bug in this code.
--
"Perl makes the fun jobs fun
and the boring jobs bearable" - me
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: File list by date
by snax (Hermit) on Dec 21, 2000 at 21:05 UTC | |
by nkpgmartin (Sexton) on May 03, 2001 at 18:36 UTC | |
by snax (Hermit) on Jun 27, 2001 at 12:44 UTC |