title: Http File upload - Files over 25mb fail - PHP uploading script
body: <p>I've been banging my head against this for 20+ hours now I would really appreciate some help!</p>
  
  <p>I have simplified the problem here so the code is very simple. Basically this upload script works perfectly until I try to upload a file bigger than 25MB then it fails. PHP gives no errors.</p>
  
  <p><strong>index.htm</strong></p>
  
  <pre><code>&lt;form enctype="multipart/form-data" action="upload.php" method="POST"&gt;
  Choose a file to upload: &lt;input name="uploadedfile" type="file" /&gt;&lt;br /&gt;
  &lt;input type="submit" value="Upload File" /&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p><strong>upload.php</strong></p>
  
  <pre><code>&lt;?php
  $target_path = "uploaded/";
  $target_path = $target_path.basename( $_FILES['uploadedfile']['name']); 
  /***/highlight_string(print_r($_FILES, true)); //check array
  
  if (move_uploaded_file($_FILES['uploadedfile']['tmp_name'], $target_path)) {
      echo "The file ". basename($_FILES['uploadedfile']['name'])." has been uploaded";
  } else {
      echo "There was an error uploading the file, please try again!";
  }
  ?&gt;
  </code></pre>
  
  <p><strong>php.ini</strong></p>
  
  <pre><code>[PHP]
  
  post_max_size = 32M
  upload_max_filesize = 32M
  </code></pre>
  
  <p>My host informed me that the upload limit on the server is 32MB. Ran phpinfo() &amp; the variables in the ini are being changed. It is not a timeout issue (ran a 16mb upload when downloading a file - it took several minutes longer than the 25MB upload but still worked).</p>
  
  <p>I have been spittin out the $_Files array as a string for error checking, heres what I get when it fails:</p>
  
  <pre><code>Array
  (
      [uploadedfile] =&gt; Array
          (
              [name] =&gt; 30.tif
              [type] =&gt; 
              [tmp_name] =&gt; 
              [error] =&gt; 7
              [size] =&gt; 0
          )
  
  )
  There was an error uploading the file, please try again!
  </code></pre>
  
  <p>Any ideas? Tried it on different servers with the same problem.</p>