3.2. PHP Directives Related to (Large) File Upload
Directives are used to configure the PHP engine. They are placed in PHP's configuration file php.ini. There are a number of directives that are related to file upload and they may be useful to you (very often you can stick with the default values and do not need to modify them). The following table lists the directives and provides a brief description of each of them:
PHP Directive |
Brief Description |
Example |
---|---|---|
file_uploads |
|
file_uploads = Off |
upload_tmp_dir |
|
upload_tmp_dir = "/temp" |
Here are some PHP directives that you may have to change in order to support large file upload. By default, files that are larger than 2MB will be rejected.
PHP Directive |
Brief Description |
Example |
---|---|---|
upload_max_filesize |
|
upload_max_filesize = 4096 |
post_max_size |
|
post_max_size = 10M |
memory_limit |
|
memory_limit = 20M |
max_input_time |
|
max_input_time = 90 |
max_execution_time |
|
max_execution_time = 60 |
Previous Page | Page 4 of 11 | Next Page |