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

XF 1.4 File Upload Problem

Discussion in 'Troubleshooting and Problems' started by Kanij Fatema, May 21, 2015.

  1. Kanij Fatema

    Kanij Fatema Member

    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?
  2. Brogan

    Brogan 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
  3. Kanij Fatema

    Kanij Fatema Member

    But those settings are already set at php.ini. However, I am using Nginx server so .htaccess method should not work.
  4. Brogan

    Brogan 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?
  5. Kanij Fatema

    Kanij Fatema Member

    there I see the followings:

    max_execution_time 30
    max_file_uploads 20
    post_max_size 50M
    upload_max_filesize 50M
  6. Kanij Fatema

    Kanij Fatema Member

    I just added the following in my nginx.conf and it is working perfect. Sorry for bothering here.

    client_max_body_size 50m;


Share This Page