title: php upload script produces error 500 for files larger than 100 Kb
body: <p>I have the following php script</p>
  
  <pre><code>&lt;?php
  
  
    if ($_FILES["file"]["error"] &gt; 0)
      {
      echo "Return Code: " . $_FILES["file"]["error"] . "&lt;br /&gt;";
      }
    else
      {
      echo "Upload: " . $_FILES["file"]["name"] . "&lt;br /&gt;";
      echo "Type: " . $_FILES["file"]["type"] . "&lt;br /&gt;";
      echo "Size: " . ($_FILES["file"]["size"] / 1024) . " Kb&lt;br /&gt;";
      echo "Temp file: " . $_FILES["file"]["tmp_name"] . "&lt;br /&gt;";
  
      if (file_exists("upload/" . $_FILES["file"]["name"]))
        {
        echo $_FILES["file"]["name"] . " already exists. ";
        }
      else
        {
        move_uploaded_file($_FILES["file"]["tmp_name"],
        "upload/" . $_FILES["file"]["name"]);
        echo "Stored in: " . "upload/" . $_FILES["file"]["name"];
        }
      }
  
  ?&gt;
  </code></pre>
  
  <p>can anyone help allow it to upload pdf files larger than around 100 Kb?</p>
  
  <p>I have checked with my hosting provider and everything is correct there, I have also checked phpinfo() which states that uploads to 8 Mb should be allowed</p>
  
  <p>Can anyone help point me in the right direction to fix this, my hosting provider suggested I create a php.ini file, but want commands does it need to contain to allow uploading?</p>
  
  <p>Thanks for your help</p>