WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Changing File Upload Limits (6 posts)

  1. Dan.LaSota
    Member
    Posted 3 years ago #

    I understand that this is an oft asked question, and I have searched these forums thoroughly.

    Question
    How do you increase the "Maximum upload file size" beyond the default so people using the "Upload New Media" page can upload larger files?

    What I have already done
    I have already edited my /etc/php.ini file with relevant lines

    memory_limit = 100M
    post_max_size =100M
    file_uploads = On
    upload_max_filesize = 100M

    These values show up when I look at a webpage powered by php_info():
    and that page verifies that it is referencing my host's php.ini file in /etc/php.ini

    I have also edited the .htaccess files in my wordpress base directory with:

    php_value upload_max_filesize 100M
    php_value post_max_size 100M
    php_value memory_limit 100M

    I have also edited the wordpress wp-config.php file with

    define('WP_MEMORY_LIMIT', '100M');

    near the top of the file.

    The resulting file upload limit from my admin media page
    /wp-admin/media-new.php
    is still 1MB

    I have also rebooted the machine, and restarted Apache.
    The machine is running PHP 5.3.6, WordPress 3.1.1 (under multisite mode), and Apache 2.2.17

    Additional Info
    The same machine is running another WordPress multisite instance which does use the 100M limit I set in the php.ini file and an additional single site instance of WordPress that also displays 100M.
    The multisite instance that I am having difficulty with does upload files just fine, as long as they are smaller than the 1MB limit (which is displayed).

    Requested Help
    What else should I edit to increase the file size limit for uploads?

  2. Dan.LaSota
    Member
    Posted 3 years ago #

    Resolved.

    Perhaps this is only for Multisite instances of WordPress, I still have all of the above factors in play: php.ini, .htaccess and wp-config.php but I also went into the root site as the super-admin user.

    1. Get to the Network Admin page. In WordPress 3.1 this link is found on the top right of the admin screens. It toggles between Site admin and network admin.
    2. Click on "Settings" in the admin panel on the left hand side of the screen.
    3. Near the bottom of this page is a section called "Upload Settings". Find it.
    4. There is a field for "Max Upload File Size". The units are KB.
    5. Convert your intended file size into KB. (100MB = 100 * 1024 * 1024KB = 104857600KB)
    6. save changes at the bottom and test for sanity.
  3. lichtung
    Member
    Posted 3 years ago #

    @Dan.LaSota,

    thank you, I had desperately the same problem, and your solution worked!

    Ter├ęz

  4. dravidian7
    Member
    Posted 2 years ago #

    Thanks this worked. I knew multisite was the problem.

  5. giveabrick
    Member
    Posted 2 years ago #

    Thanks very much. This is great! I changed the settings via network as suggested before having done any of that other stuff with .htaccess etc. and it worked. Delighted :-)

  6. Dan.LaSota
    Member
    Posted 2 years ago #

    sweet!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.