Re: Quickform maxFileSize request for change in behaviour
| From: | Alexey Borzov | Date: | Wed, 27 Jul 2005 13:09:31 +0000 |
| Subject: | Re: Quickform maxFileSize request for change in behaviour | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-38971@lists.php.net to get a copy of this message | ||
Hi,
Yuri Weseman wrote:
Today I tried uploading a file using Quickform. It works, but only when your files are smaller than 1MB. Quickform uses a hidden input field, named MAX_FILE_SIZE. This prevents files larger than that size from being upoaded. The value is hardcoded to 1 megabyte in Quickform.php. I'd like to suggest to change this behaviour. I've added a patch file, that shows the change. The patch file was created with diff on version 3.2.4pl1 (QuickForm.php,v 1.151).Please note that this value is not exactly "hardcoded" as it can be changed by using setMaxFileSize(): http://pear.php.net/manual/en/package.html.html-quickform.html-quickform.setmaxfilesize.php
In the constructor of Quickform.php I would add a check for the value of upload_max_filesize. If it is correctly set, we can use this value to set the default behaviour to use this value instead of 1MB.Your idea makes sense, problems with default 1 meg upload bit even me... Can you please open a feature request in PEAR's bug tracker so that it will be easier to find it later?