in reply to RE: Re: File Upload + recording
in thread File Upload + recording "metadata"

You're right about the open on the OUPUT filehandle. I think we're both right on the first thing (param vs. upload), though. :) As the CGI.pm docs say this:
To be safe, use the upload() function (new in version 2.47). When called with the name of an upload field, upload() returns a filehandle, or undef if the parameter is not a valid filehandle. $fh = $query->upload('uploaded_file');
Calling param on an uploaded file field gives you a thing that's both a string and a filehandle. Using upload just makes sure you get a filehandle, as it's less of a security risk.

As to your question re: big uploads: do you get any out of memory errors? 60-70k doesn't seem like *that* big a value. Could it be a POST limitation?

Replies are listed 'Best First'.
RE: RE: RE: Re: File Upload + recording
by brett (Initiate) on Jun 15, 2000 at 08:44 UTC
    Yes, my apologies. It turns out I was using an old version of CGI.pm Upgraded and unearthed the upload() function.
    Just trolled the apache error logs and can see an error message being generated from mod_perl:
    [client xxx.xx.xxx.xxx] Request content-length of 84482 is larger than the configured limit of 75000
    Which probably explains my problem with file upload size :)
    Thanks a lot for your help.

    *a bit later* Turns out this:

    LimitRequestBody 75000
    was in my httpd.conf file! *slaps forehead*
      I think the maximum request size is configurable. Check out the LimitRequestBody directive in the Apache docs.