in reply to creating a file with a cgi script
I'd guess that the web server user doesn't have rights to write to that directory. You don't seem to be doing any kind of error checking.
And that's not a very portable or efficient way to write to a file. Why not use "open", "flock" and "print"?
Two other small points. Firstly, writing log files in your cgi-bin isn't a very good idea. Depending on how your web server is configured, it's possible that the server will try to execute them when they are requested by a browser. Secondly, I'm not sure what is in you $par2 variable, but the syntax of your "cat" call doesn't look right.
"The first rule of Perl club is you do not talk about
Perl club."
-- Chip Salzenberg
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: creating a file with a cgi script
by Anonymous Monk on May 19, 2006 at 08:15 UTC | |
by davorg (Chancellor) on May 19, 2006 at 08:21 UTC | |
by Anonymous Monk on May 19, 2006 at 08:29 UTC | |
by davorg (Chancellor) on May 19, 2006 at 08:35 UTC | |
by izut (Chaplain) on May 19, 2006 at 09:18 UTC |