wolverina has asked for the wisdom of the Perl Monks concerning the following question:
why doesn't this code work?
$TextFile = "script.pl"; use Cwd; chdir("$ENV{DOCUMENT_ROOT}/some_directory") or die $!; my $dir = getcwd; open (DAT,">${dir}${TextFile}") or die $!; print DAT ("$ENV{DOCUMENT_ROOT}/cgi_bin/$text\n") or die $!; close(DAT) or die $!;
There's no server error, but the file is not written to another directory. Lisa.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: output to another directory
by frankus (Priest) on Aug 09, 2002 at 11:20 UTC | |
|
Re: output to another directory
by dda (Friar) on Aug 09, 2002 at 11:17 UTC | |
|
Re: output to another directory
by demerphq (Chancellor) on Aug 09, 2002 at 12:05 UTC |