How do I change my 'upload' limit. (6 posts)

  1. nhga
    Posted 7 years ago #

    I need to upload a particularly large pdf file as part of a Lesson Plan. If I use the media uploader, it tells me that the file is to large. If I use my FTP and upload it via Bluehost, I can never find the pdf after it's uploaded.
    Can anyone give me some instructions on what is the best way to deal with this problem.

  2. Josh Leuze
    Posted 7 years ago #

    It looks like other people have had this problem too. I think you may need to increase your PHP memory limit in php.ini to be able to do this.

  3. nhga
    Posted 7 years ago #

    I followed the instructions and reset the limit in php.ini. I also reset it in settings (per instructions).
    I now have this message when I try to get to my page.
    <Fatal error: Allowed memory size of 262144 bytes exhausted (tried to allocate 30720 bytes) in /home2/nhganet/public_html/wp-includes/functions.php on line 1559>

    Line 1559 is <@chmod( $target, $dir_perms );>
    Can you tell me what I need to fix?

  4. Josh Leuze
    Posted 7 years ago #

    That's not good! I would change it back and make sure it still works.

    Maybe try consulting your webhost, I think that this size limit could be set at a few different levels, and the changes you made might not be kosher with their set up. They may need to lift this size limit on their end, or they may suggest an alternative way to change the limit.

  5. BernardBorealis
    Posted 7 years ago #

    Try increasing all of the following in your php,ini

  6. matjes
    Posted 7 years ago #

    I had problems with editing the php.ini file because with most webhosts it is globally and inaccessable for us and you still would have to add a line in .htaccess anyway. But I found an easier way if you have access to the .htaccess file in your www folder. Just include the following 2 lines in .htaccess:

    php_value upload_max_filesize 20M
    php_value post_max_size 20M

    For changing the memory limit add/edit this in .htaccess:

    php_value memory_limit 20M

    And of course change the 20 to anything you need.

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.