XF 1.4 File Upload Problem

I can not upload pdf file of size greater than 2 MB. When I try it says "File Not selected".

I have checked attachment settings where pdf files are allowed and max file upload limit set to 30MB. I have checked my LEMP set up where File Upload limit is set to 50MB both in PHP and in Nginx. I am running 4 websites in the same linode VPS. But only with xenforo installation this 2 MB limit apply.

Is there anything, I need to change from xenforo part?


XenForo moderator
Staff member
There are a couple of PHP settings which need to be increased to support large uploads.
Try adding the following lines to your .htaccess file:

php_value upload_max_filesize 30M
php_value post_max_size 30M
But those settings are already set at php.ini. However, I am using Nginx server so .htaccess method should not work.


XenForo moderator
Staff member
If they are already set in php.in then there is another issue at play.

if you go to admin.php?tools/phpinfo what do you see for the various settings?
there I see the followings:

max_execution_time 30
max_file_uploads 20
post_max_size 50M
upload_max_filesize 50M
I just added the following in my nginx.conf and it is working perfect. Sorry for bothering here.

client_max_body_size 50m;