in reply to Create html file from script
Please be aware that you are attempting to open an INPUT file, (even though the filehandle is called OUTPUT). That's because the default mode of open is "read".
To open a file for output, you should do either:
open(OUTPUT, ">$outputFile");
Or even better...
open(OUTPUT, ">", $outputFile);
And best of all, because it checks for an error condition:
open(OUTPUT, ">", $outputFile) or die "Failed to write to '$outputFile +' ($!)\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Create html file from script
by ww (Archbishop) on Jul 18, 2006 at 17:14 UTC |