Configuring php.ini

The php.ini file location can be found on the PHP Info page in the row "Loaded Configuration File", available by running the function phpinfo() on an empty PHP page:

<?php phpinfo(); ?>

Increasing the following variables allows for handling much larger files, the default values are set quite low which can cause issues when uploading large media files:

  • memory_limit
    • This should be set to suit your expected usage. If using plugins (e.g. tms_link) to integrate with other systems then this may need to be higher than normal.
    • Suggested value 999M.
  • post_max_size
    • Ensure this is set above the default upload chunk size ($plupload_chunk_size in ResourceSpace config, 5MB by default).
    • Suggested value 999M.
  • upload_max_filesize
    • Ensure this is also set above the default upload chunk size.
    • Suggested value 999M.
  • max_execution_time
    • Default is 30 seconds. This may need to be increased if you need to upload larger files and are creating previews at the point of upload as this can cause the preview generation time to exceed the limit.
    • NOTE: If you are using a Windows server please also check other IIS/FastCGI timeout settings.

The "short_open_tag" value should be Off (On will likely still work, but any problems with Off should be reported).

If you do not have access to the php.ini file then you may be able to override the settings by creating a file named '.htaccess' in the root folder with the following contents:

SecFilterEngine Off
SecFilterScanPOST Off
php_value memory_limit 999M
php_value post_max_size 999M
php_value upload_max_filesize 999M
php_value short_open_tag Off