What's new
DevAnswe.rs Forums

Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts.

XenForo "Oops! We ran into some problems. The uploaded file is too large."

Solution
@josephp as well as PHP settings, you have to change XenForo settings also.

Go to Setup > Options > Attachments. There is an upper limit set there of 1024KB (1MB) which you need to change. Maybe set it to 8MBs if you want people to paste into the forum (as josephp says, the OS pastes raw PNG without compression).

josephp

New member
You need to increase the upload_max_filesize value in PHP settings.


If on PHP 8.1

Bash:
sudo nano /etc/php/8.1/apache2/php.ini

upload_max_filesize​

In nano, press CTRL + W and search for upload_max_filesize and change the value to 16M (for 16 megabytes) or whatever value you require.

Code:
upload_max_filesize = 16M

post_max_size​

Press CTRL + W again and search for post_max_size and change the value to 16M (for 16 megabytes) or whatever value you require.

Code:
post_max_size = 16M

Save and exit (press CTRL + X, press Y and then press ENTER)


Warning though: 16MBs is probably too much to allow on a forum - that will eat up your space once you get a lot of traffic,
 

josephp

New member
It's the OS I think. When you press copy, you're not actually copying a JPG. Instead, you're copying the raw, uncompressed image data. When you paste, it seems that the browser has to determine how to handle the raw image data, and it appears to save it as a PNG.
 

codeMtim

New member
@josephp as well as PHP settings, you have to change XenForo settings also.

Go to Setup > Options > Attachments. There is an upper limit set there of 1024KB (1MB) which you need to change. Maybe set it to 8MBs if you want people to paste into the forum (as josephp says, the OS pastes raw PNG without compression).
 
Last edited by a moderator:
Solution
Top