XF 2.0 $config['maxImageResizePixelCount'] breaks forum

BobHarbison

Active member
I wanted to increase the maximum image size, so I added this to my config.php $config['maxImageResizePixelCount'] = '30000000'

The entire forum refuses to load when I tried that. Any ideas what I'm doing wrong?
 
OK, I'm an idiot. But, I now have a new problem.

The image uploads and doesn't give an "image too large" error. However, now it simply shows the file name with a line through it once it has finished uploading. So it's still rejecting it somehow.
 
Server error log doesn’t show any errors. There’s no error message when uploading either, it appears to work, you do not get the file too large error. However, the result is what you see above, a line through the image name as if it was deleted.
 
No, that's not the issue. It's definitely pixel count. I've got upload size set to 10 MB in php.ini as well as in attachment options. The file size is only 800KB, but over the 20K pixels. It uploads but gives me that result. A 950K version of the same file, but re-sized to fit under the 20K pixels works just fine, even though it's a larger file size in MB. So it's like something is still "remembering" the 20K pixel limit.
 
Last edited:
I've opened a ticket on this and so far, no luck. It works fine with images up to and including 24 mp. But a 36 mp image gives the "instant delete" problem shown above. I've looked at the server error log, php error log and xenforo error log and none of them are showing anything.

Anyone else seen this issue? If so, how have you fixed it?
 
Btw, I have determined, through repeated tests, that it’s dimensions, not file size, that cause the issue. I’ve compressed that image to the point it’s a low res posterized mess, and still no luck. OTOH, a 24 MP image 3 times as big (in kB) works just fine.
 
Here’s a couple sample images that break it
https://cdn1.sbnation.com/assets/3400181/DSC00879.JPG

1) I saved this image to my computer.
2) I uploaded as an attachment the image to my forum.

No problem at all, it reduced the size to 140 KB and the new dimensions are 1600 x 1068.

Here are my attachments settings:

Admin control panel -> Setup -> Options -> Attachments

Maximum attachment file size = 50000
Maximum attachment image dimensions = 1600 x 6000
Default image processor = Imagemagick PECL extension

In the config.php file I have:

$config['maxImageResizePixelCount'] = 100000000;
 
Last edited:
OK, that makes sense. Unfortunately, changing it to 6000 didn't help. I've changed my php.ini settings to match yours, (most were already there) and no luck there either.
 
Back
Top Bottom