title: PHP see only 20 uploading files at a time
body: <p>When I try to upload more than 20 files at a time, then the web server see only first 20. Any other files are just ignored. What is the problem?</p>
  
  <p>Simple code to try:</p>
  
  <pre><code>&lt;form action="index.php" method="post" enctype="multipart/form-data"&gt;
  &lt;?php
  if($_FILES){
      print_r($_FILES);
  }
  else{
      for($i = 0; $i &lt; 30; $i++)
      {
          echo '&lt;input type="file" name="file'.$i.'"&gt;&lt;br/&gt;';
      }
  }
  ?&gt;
  &lt;input type="submit" value="go"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p><code>print_r()</code> output:</p>
  
  <pre><code>Array ( [file0] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpD42.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file1] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpD52.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file2] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpD73.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file3] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpD83.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file4] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpD94.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file5] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpDB4.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file6] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpDC5.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file7] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpDE5.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file8] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpDF5.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file9] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpE06.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file10] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpE26.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file11] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpE37.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file12] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpE57.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file13] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpE68.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file14] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpE78.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file15] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpE98.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file16] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpEB9.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file17] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpEC9.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file18] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpEE9.tmp [error] =&gt; 0 [size] =&gt; 274217 ) [file19] =&gt; Array ( [name] =&gt; 39442.jpg [type] =&gt; image/jpeg [tmp_name] =&gt; W:\tmp\phpEFA.tmp [error] =&gt; 0 [size] =&gt; 274217 ) )
  </code></pre>
  
  <p>.htaccess:
  php_value max_file_uploads 100  - doesn't help</p>
  
  <pre><code>ini_set('max_file_uploads', 100) - doesn't help
  </code></pre>
  
  <p>I just added line to php.ini on my local server :</p>
  
  <pre><code>max_file_uploads = 100
  </code></pre>
  
  <p>And it's helped. But I don't think that the hoster change it on client's web server. It would be very cool effect on this value without editing <code>php.ini</code>.</p>