Your conditional statement may be causing the problem.  If your
if-statement return false, your output file will not be created; so you
can't write into it.

If you want to see whether the file exist,  then use:
If (! -e $name){ open (OUT, ">$name");}




> Hi,
> My cgi script has been written in order to collect some parameters
(with the
> POST method) but actually if I want to record them, I can just put
them in a
> pre-existent file. I am unable to create a new file, even with a
'chmod 777'
> on my directory...
> I would have a result like this:
> 
> #####test.cgi##########
> $name=$$.$var;
> if ( ! -f ./$name){
>       open (OUT,">$name");
> }
> foreach $i (@DATA){
> ...
> print OUT "$i\n";
> ...
> }
> close OUT;
> 
> 
> Does anybody have an idea?



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to