Upload file size
-
user 007elt helped with the below solution to limit upload file size:
https://www.ads-software.com/support/topic/how-to-limit-file-upload-size/
I added the following to my child functions php and it seems to be working C:
// Users cannot upload large files Limit upload size for non-admins. Admins get the default limit
function increase_upload_size_limit( $limit ) {
if ( ! current_user_can( ‘manage_options’ ) ) {
$limit = 1048576; // 1 MB
}
return $limit;
}
add_filter( ‘upload_size_limit’, ‘increase_upload_size_limit’ );See also
https://www.ads-software.com/support/topic/how-to-limit-file-upload-size/
Plugin below appears to be only for images and not files!
https://www.ads-software.com/plugins/wp-image-size-limit/
- The topic ‘Upload file size’ is closed to new replies.