Help for this page

Select Code to Download


  1. or download this
      <FORM ENCTYPE="multipart/form-data" ACTION="upload.cgi" METHOD=POST>
        Upload this file: <INPUT NAME="userfile" TYPE="file"><br>
        Description:<input type="text" name="description"><br>
        <INPUT TYPE="submit" VALUE="Send File">
      </FORM>
    
  2. or download this
      $rawfile = $cgi->param("userfile");        
      if ( $rawimage =~ /([\w\s\W]+)\.(\w+)/ ) {
    ...
        print OUTFILE $buffer or die "Could not upload file $filename: $!"
    +;
      }
      close (OUTFILE);
    
  3. or download this
      use CGI qw(:all escape);
      use CGI::Carp qw(fatalsToBrowser);
    ...
      open (x,">$tempfile");
      print x $buffer;
      close (x);