Hi,
I am trying to implement file size validation for an upload field on a
form.
For security / performance the php.ini post_max_size config setting is
set to 8 mb.
Now I want to limit the file size upload to about 1 mb. I am using the
built in sfValidatorFile:
$this-setValidator(file, new
This is actually a php limit. Not a Symfony one. There's not much you can do
besides increasing your php max_post_size value. (but I wouldn't do this).
Nathan
--
nathan @ http://twitter.com/nathan_gs nathan.gs
http://nathan.gs/?utm_source=mailing-listutm_medium=emailutm_campaign=blog
On Thu,
I want to allow users to upload image files of upto 1 MB in size...
I tried with YML...
fields:
...
file:
file: True
sfFileValidator:
mime_types:
- 'image/jpeg'
- 'image/png'
- 'image/gif'
- 'image/bmp'
mime_types_error: Please upload