• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.4 Image Upload issue

#1
Good morning, I am a new install, and am trying to configure the image upload, when uploading an image to my board I get an error.

I have set the max file size to be 6 meg, 2048x2048 as the max image size, but whenever I upload a 4 meg file, it does the upload and gives this error: "The uploaded file is too large for the server to process. "

Am I missing something? Image is 4000x3000 pixels and 4.32MB

I am using GD ...
 

Brogan

XenForo moderator
Staff member
#7
It's a server file.
If you contact your host they should be able to change it for you.

Unless you're on shared hosting, in which case you can try changing the values in .htaccess.
 
#8
Hi Brogan

My host doesn't provide these services. I paid Xenforo for the installation service as I know it's beyond my capability, I assumed it would be ready to use... is there a step-by-step guide for a non-developer person such as myself that I can follow to fix this up?

Thanks
 

Mike

XenForo developer
Staff member
#9
Php.ini is part of the underlying PHP package. XenForo just builds on top of that, so we assume that the underlying package is configured correctly. This is normally part of the server maintenance side of things that would either be handled by a shared server or at least something like a managed VPS. Are you on an unmanaged server then?
 

Brogan

XenForo moderator
Staff member
#10
XenForo is ready to use but this is server related, external to XenForo.

If you don't know where or how to change it yourself then you will need a sysadmin or similar to help you with server config.

Otherwise, you can try adding the relevant lines to the .htaccess file as I suggested, adjusting the values to suit:
Code:
php_value upload_max_filesize 10M
php_value post_max_size 10M
Edit: That's probably unlikely to work though, due to the server set up, so you could try creating a local php.ini file in the same directory and adjusting those two lines, but again you would need to find and copy the existing php.ini file, which you can do by navigating to admin.php?tools/phpinfo and checking the 'Loaded Configuration File' path.
 

Brogan

XenForo moderator
Staff member
#12
Actually, you're with Tsohost which should be a managed server?

There are instructions here on how to set up a local php.ini file though: https://www.tsohost.com/knowledge-base/article/244/an-introduction-to-custom-php-ini

What's interesting there is the default is 100M, so you shouldn't be having any issues.

It may be worth posting the two values for those settings so we can see what they are.
Navigate to admin.php?tools/phpinfo and do a search for them.
 
#14
Ok, so its saying:
upload_max_filesize 100M 100M
post_max_size 100M 100M
max_file_uploads 20 20

I just tried uploading again and it's working perfectly so I don't know what was going on yesterday...

Sorry... :confused: