DaWolf has asked for the wisdom of the Perl Monks concerning the following question:
Well, how can this same code works in one kind of situation and don't work on other kind?$file_folder = "foo/foo2/"; tie %arquivos, IO::Dir, $file folder; if (scalar ( keys %arquivos) ne 0) { foreach (keys %arquivos) { if ($_ ne "." and $_ ne "..") { <a href=\"$file_folder$_\">$_</a>\n"; } } } else { print "There are no files\n"; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: IO::Dir confusing behaviour
by MZSanford (Curate) on Nov 21, 2001 at 19:02 UTC | |
Re: IO::Dir confusing behaviour
by IOrdy (Friar) on Nov 21, 2001 at 19:07 UTC | |
by DaWolf (Curate) on Nov 21, 2001 at 19:17 UTC | |
(tye)Re: IO::Dir confusing behaviour
by tye (Sage) on Nov 21, 2001 at 22:48 UTC | |
by DaWolf (Curate) on Nov 21, 2001 at 23:14 UTC | |
Re: IO::Dir confusing behaviour
by mce (Curate) on Nov 21, 2001 at 20:42 UTC | |
Re: IO::Dir confusing behaviour
by Amoe (Friar) on Nov 21, 2001 at 21:29 UTC | |
by DaWolf (Curate) on Nov 21, 2001 at 22:10 UTC | |
Re: IO::Dir confusing behaviour
by DaWolf (Curate) on Nov 21, 2001 at 22:24 UTC |