Support has been upgraded!
The Support Forum is closed. Not to worry! Providing the top quality support you expect and we're known for will continue! We're not ending support, just changing where you submit requests. This will provide you with the best experience possible.
Premium Support
Have you purchased an addon for Connections such as one of our premium templates or extensions with a valid license and you need help?
Please open a Support Ticket in your user account.
Free Support
Are you using the free Connections plugin? Don't worry, you are still very important to us! We are still providing you with the same high quality support that we're known for.
Please open a new support topic in the WordPress support forums for Connections.
Tagged: 8.5.20, image, memory_limit, post_max_size, upload, upload_max_filesize, wp_max_upload_size
- This topic has 7 replies, 2 voices, and was last updated 10 years ago by
Darrin Goodman.
-
AuthorPosts
-
07/25/2016 at 1:22 pm #384088
Darrin Goodman
ParticipantHi Steven,
Recently I have not been able to upload images into our Connections online directory. When I try to upload an image, I get the following alert popup: “Selected image exceeds maximum upload file size of 0 TB. Please choose a different image.” I see that a similar problem was addressed in this forum at the link below, but I did not see a solution to the issue: http://connections-pro.com/support/topic/maximum-upload-file-size-wrong/
We have been trying to allow larger file size uploads for our Multisite users, but I’m not sure how increasing file upload size would have broken the image upload feature in Connections. I was wondering if you might have any ideas please as to a solution; we need to be able to upload images into our directory.
Thank you!
-Darrin
07/25/2016 at 1:30 pm #384089Darrin Goodman
ParticipantThis reply has been marked as private.07/25/2016 at 4:06 pm #384101Steven Zahm
Keymaster@ Darrin
Connections uses the core WP function wp_max_upload_size() to determine the max upload size of a file.
This core WP function uses the smallest of the server PHP environment vars
upload_max_filesizeandpost_max_size.One of those two seem to be set to 0TB.
Take a read of this tutorial:
https://kinsta.com/blog/increasing-the-maximum-upload-size-in-wordpress/It seems pretty accurate as most do not even mention that
post_max_sizeneeds to be large thanupload_max_filesize(not by much 1MB s/b more than plenty).Also, I high recommend making the max less than the
memory_limitvalue. Images when opened for processing such as scaling/cropping can take 3—5 times the available memory.Hope this helps, let me know.
07/26/2016 at 3:30 pm #384223Darrin Goodman
ParticipantThanks for your help Steven – I read through the tutorial and implemented the changes without success. I still get the message indicating that files larger than 0 TB cannot be uploaded. Any other ideas? What I have implemented is detailed below. Thank you! I have increased memory as follows:
-==[ PHP.INI FILE EDITS (/etc/php.ini) ]==- post_max_size = 70M upload_max_filesize = 65M memory_limit = 128M -==[ .HTACCESS FILE EDITS ]==- # Increase maximum upload time # Source: https://kinsta.com/blog/increasing-the-maximum-upload-size-in-wordpress php_value upload_max_filesize 65M php_value post_max_size 70M php_value memory_limit 128M -==[ WP-CONFIG.PHP FILE EDITS ]==- // This might somehow increase the file upload limit in WP. // Source: https://wordpress.org/support/topic/how-to-increase-the-max-upload-size define('WP_MEMORY_LIMIT', '128M'); // More efforts to increase file upload size // Source: https://kinsta.com/blog/increasing-the-maximum-upload-size-in-wordpress @ini_set( 'upload_max_size' , '65M' ); @ini_set( 'post_max_size', '70M'); @ini_set( 'memory_limit', '128M' );07/26/2016 at 3:41 pm #384228Steven Zahm
Keymaster@ Darrin
Well…everything looks correct but WP is still reporting
0TB. If you can give me an FTP login, I can take a closer look.07/26/2016 at 3:52 pm #384229Darrin Goodman
ParticipantThis reply has been marked as private.07/26/2016 at 4:45 pm #384235Steven Zahm
Keymaster@ Darrin
The cause is the the
../wp-includes/default-constants.phpseems to have been replaced with either an older or an altered version. The file being used does not include new constants included in WP 4.4 for byte sizes. They are;KB_IN_BYTES,MB_IN_BYTES,GB_IN_BYTESandTB_IN_BYTES.Because those constants were not set it would cause the core WP function
wp_max_upload_size()to return a0value. Fortunately thewp_max_upload_size()function includes a filter namedupload_size_limit.Add added a new filter in the
../wp-content/plugins/connections/includes/inc.plugin-compatibility.phpwhich check for those constants and then set them so thewp_max_upload_size()function will function correctly.This should resolve the upload issue. Hope that helps!
07/26/2016 at 6:29 pm #384269Darrin Goodman
Participant@Steven – THANK YOU SO VERY MUCH!!! I owe you a beer or three! I’m not sure why the default-constants.php file is not the most recent… I’ll look into that.
Thank you!
-
AuthorPosts
You cannot reply to this support topic. Please open your own support topic.
