rsiedl has asked for the wisdom of the Perl Monks concerning the following question:
The above creates the file perfectly but amy $field = $q->param("author"); $field =~ s/ /_/g; open(OUTFILE,">"./$field.txt") || die($!); print OUTFILE "blah"; close(OUTFILE);
if ($item =~ /^$field\.(txt|foo|bar)$/i)wont match until I remove the initial "^".
$field = "blah-$field";before the creation of the "OUTFILE", the script dies while trying to create the file with the message
No such file or directory
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Special Chars in CGI form variables
by cazz (Pilgrim) on Apr 20, 2005 at 13:14 UTC | |
|
Re: Special Chars in CGI form variables
by polettix (Vicar) on Apr 20, 2005 at 13:25 UTC | |
by rsiedl (Friar) on Apr 20, 2005 at 13:31 UTC | |
by cazz (Pilgrim) on Apr 20, 2005 at 13:49 UTC | |
by polettix (Vicar) on Apr 20, 2005 at 13:41 UTC |