e5an Posted September 22, 2021 Share Posted September 22, 2021 Trying to upload files on the backend: 'Field is too big - maximum allowed size is 2048 kb' I found that it's supposed to be using ini_get('post_max_size') to get this value. When I print the value of ini_get('post_max_size') , it says '8M' which I confirmed is the limit it is set to in the php.ini, which I confirmed is the correct php.ini with phpinfo(). I also tried putting the line 'php_value upload_max_filesize 10M' at the end of the .htaccess in the processwire folder. This did nothing. I really need to be able to upload larger files, so I really need to know where this 2MB limit is coming from and how to change it but I am out of ideas. Link to comment Share on other sites More sharing options...
teppo Posted September 22, 2021 Share Posted September 22, 2021 What's the value of upload_max_filesize in php.ini, and is your web server Apache or nginx? Asking because... upload_max_filesize limits the maximum size of any single file (post_max_size is the maximum size of entire request), and if you're running on nginx then there may be other directives (such as client_max_body_size) that also affect this. Quote I also tried putting the line 'php_value upload_max_filesize 10M' at the end of the .htaccess in the processwire folder. Depending on server config this may not work at all. If you have access to php.ini, that's definitely more likely to work. 2 1 Link to comment Share on other sites More sharing options...
e5an Posted September 22, 2021 Author Share Posted September 22, 2021 Thanks, the upload_max_filesize fixed it. Didn't know that was a separate thing. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now