WordPress.org

Ready to get started?Download WordPress

Forums

Fatal error - Out of Memory - when uploading images (11 posts)

  1. Ted Muir
    Member
    Posted 1 year ago #

    While uploading images for a news post, I got the following message :

    Fatal error: Out of memory (allocated 50855936) (tried to allocate 15388 bytes)........

    I have tried searching the solution on the support forums which recommend making changes to wp-settings.php and wp-config.php

    However the above php files do not have the required code to be modified.

    I would need someone to suggest the solution please......

  2. kjodle
    Member
    Posted 1 year ago #

    However the above php files do not have the required code to be modified.

    Try adding this line to your config.php file:
    define('WP_MEMORY_LIMIT', '64M');

    Have you read this?
    http://codex.wordpress.org/Editing_wp-config.php#Increasing_memory_allocated_to_PHP

  3. Ted Muir
    Member
    Posted 1 year ago #

    Thx Kjodle. Do you have any particular order where to add this ?

    I added right at the bottom like shown.

    define('AUTH_KEY', 'put your unique phrase here');
    define('SECURE_AUTH_KEY', 'put your unique phrase here');
    define('LOGGED_IN_KEY', 'put your unique phrase here');
    define('NONCE_KEY', 'put your unique phrase here');
    define('AUTH_SALT', 'put your unique phrase here');
    define('SECURE_AUTH_SALT', 'put your unique phrase here');
    define('LOGGED_IN_SALT', 'put your unique phrase here');
    define('NONCE_SALT', 'put your unique phrase here');
    define('WP_MEMORY_LIMIT', '64M');

    But the problem still persists. When uploading image in a new post, the following fatal error message came up :

    Fatal error: Out of memory (allocated 50855936) (tried to allocate 14592 bytes) in /homepages/40/d210766793/htdocs/Ads/wordpress/wp-includes/media.php on line 258

  4. Try adding it a few lines of white space below the opening <?php of wp-config.php:

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

    If that doesn't work, ask your host; thay may have memory limits on your account.

    They may also need to increase the php upload limits, which are different than overall memory allocation.

  5. kjodle
    Member
    Posted 1 year ago #

    If that doesn't work, ask your host; thay may have memory limits on your account.

    Very true; a lot of hosts limit memory, especially on shared servers.

    I have tried searching the solution on the support forums which recommend making changes to wp-settings.php and wp-config.php

    However the above php files do not have the required code to be modified.

    Help us to help you: either give us links to these threads, or indicate what you have already tried.

  6. Ted Muir
    Member
    Posted 1 year ago #

    Thanks songdogtech and kjodle for your replies.

    Since the ones you suggested didn't help to solve, I will have to speak to the hosting company 1&1 to find a possible solution.

    Thanks again!

  7. I will have to speak to the hosting company 1&1.....

    That's the whole problem. 1&1 is well known as a crappy host. It's very doubtful they will allocate more memory to your account.

  8. Ted Muir
    Member
    Posted 1 year ago #

    Do you think it is a hosting issue and not related to wordpress theme or anything like that ?

  9. kjodle
    Member
    Posted 1 year ago #

    As songdogtech said, 1&1 has a well-established reputation that makes people go "yuck!" You can ask them what the memory limit is on your account and if they can raise it. If not, the only solution is to find another host.

  10. Ted Muir
    Member
    Posted 1 year ago #

    My current hosting plan has 30MB memory for php.

    I spoke to 1&1. They have new plans with up to 80MB memory for php.

    I hope upgrading to new plan will get rid of this misery.

  11. moregone
    Member
    Posted 1 year ago #

    Hello,

    I just ran into this same issue with my 1and1 account. I too have called and am upgrading to the 80mb. This seems like it will only be short term fix as I am coming from 60mb account. What I would like to know is how do I manage the size of php? Iv'e only got 20mb left and I feel like my website is in it's toddler stages still, and I have tons of content I intend to post.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.