in reply to •Re: Uploading files: can't find contents?
in thread Uploading files: can't find contents?

Actually he is explicitly following this advice merlyn (making the presumption that $this->cgi is a CGI object). No doubt he will be missing the ENCTYPE="multipart/form-data" in the FORM TAG or have uploads disabled $CGI::DISABLE_UPLOAD or be exceeding $CGI::POST_MAX.

One of the less user friendly things about CGI.pm is that if misses the opportunity to report the cause of failing file uploads and leave a useful message in err_str()

cheers

tachyon

s&&rsenoyhcatreve&&&s&n.+t&"$'$`$\"$\&"&ee&&y&srve&&d&&print

  • Comment on Re: •Re: Uploading files: can't find contents?

Replies are listed 'Best First'.
•Re: Re: •Re: Uploading files: can't find contents?
by merlyn (Sage) on Apr 04, 2003 at 01:03 UTC
Re: Re: •Re: Uploading files: can't find contents?
by maksl (Pilgrim) on Apr 04, 2003 at 15:22 UTC
    how could i access $CGI::DISABLE_UPLOAD ?
    #!/usr/bin/perl -w use CGI; print "CGI::DISABLE_UPLOADS: $CGI::DISABLE_UPLOADS\n";
    gives:
    Name "CGI::DISABLE_UPLOAD" used only once: possible typo at cgi-bin/te.pl line 3.
    Use of uninitialized value in concatenation (.) at cgi-bin/te.pl line 3.
    CGI::DISABLE_UPLOAD:
    thx maksl

    Update:
    the other name variable gives CGI::POST_MAX: -1, perhaps my version of CGI can't disable upload?

    Update2:
    added plural to above, thx jasonk .. this results in CGI::DISABLE_UPLOADS: 0

      It's plural... $CGI::DISABLE_UPLOADS.


      We're not surrounded, we're in a target-rich environment!