in reply to Re: File upload under Apache2
in thread File upload under Apache2

CGI::Simple uses the exact same interface as CGI, and CGI::UploadEasy and CGI::Upload aren't any easier to use

Replies are listed 'Best First'.
Re^3: File upload under Apache2
by CountZero (Bishop) on Aug 16, 2010 at 10:24 UTC
    Beauty or (ease of use) is in the eye of the beholder and sometimes things need to be repeated before they sink in.

    CountZero

    A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

Re^3: File upload under Apache2
by wfsp (Abbot) on Aug 17, 2010 at 07:43 UTC
    Minor quibble. It's not "the exact same interface".

    From the docs:

    By utilizing a new feature of the upload method this process can be si +mplified to: $ok = $q->upload( $q->param('upload_file1'), '/path/to/write/file. +name' ); if ($ok) { print "Uploaded and wrote file OK!"; } else { print $q->cgi_error(); } As you can see upload will accept an optional second argument and will + write the file to this file path. It will return 1 for success and u +ndef if it fails. If it fails you can get the error from cgi_error.
    imo, a nice improvement.