title: PHP, Zend Framework: How to set the upload max filesize?
body: <p>I'm setting the upload max filesize in my form:</p>
  
  <pre><code>$file = new Zend_Form_Element_File('file');
  $file-&gt;setLabel('File to upload:')
      -&gt;setRequired(true)
      -&gt;addValidator('NotEmpty')
      -&gt;addValidator('Count', false, 1)
      -&gt;addValidator('Size', false, 10485760) //10MB = 10,485,760 bytes
      -&gt;setMaxFileSize(10485760)
      -&gt;setDestination(APPLICATION_UPLOADS_DIR);
  $this-&gt;addElement($file);
  </code></pre>
  
  <p>But I'm getting this error message in my Zend Framework application:</p>
  
  <pre><code>Notice: Your 'upload_max_filesize' config setting limits the maximum filesize to '2097152'. You tried to set '10485760' in /location/to/Zend/Form/Element/File.php on line 620
  </code></pre>
  
  <p>What am I doing wrong?</p>