[wp-hackers] Memory size error when uploading images
christian at buro2.se
Wed Mar 2 17:38:49 UTC 2011
2011/3/2 Christian Gundersson <christian at buro2.se>
> Yes, but only through wp-config.php and .htaccess. I don't have access to
> php.ini unfortunately and the webhost is closed until tomorrow.
> But I'm not sure that it really is a memory size problem. All reported
> issues like this that I have read, where the allocated size is smaller than
> the limit, have not been resolved by increasing the PHP memory allocation
> limit. I'll try that just to be sure tomorrow, but I'd like to get a heads
> up on the problem if that doesn't solve it :)
> 2011/3/2 Martin Buckley <martin at buckleymail.com>
> Have you tried increasing your PHP memory allocation?
>> -----Original Message-----
>> From: wp-hackers-bounces at lists.automattic.com [mailto:
>> wp-hackers-bounces at lists.automattic.com] On Behalf Of Christian
>> Sent: Wednesday, March 02, 2011 9:28 AM
>> To: wp-hackers at lists.automattic.com
>> Subject: [wp-hackers] Memory size error when uploading images
>> I have a problem and can't seem to get the suggested solutions from the
>> internets to work. Anyone got a hint I'll be glad to listen...
>> I get the error below when I upload an image through the media library
>> (either directly or from within a post).
>> *Fatal error*: Allowed memory size of 33554432 bytes exhausted (tried to
>> allocate 5004 bytes) in *wp-includes/media.php* on line *254*
>> A very weird message since it tries to allocate a smaller amount than the
>> limit, but anyhew.
>> I've looked in the wp_postmeta table after uploading an image and the
>> entry for _wp_attached_file is there and looking as it should. However, the
>> accompanying entry for _wp_attachment_metadata is missing. It feels as
>> though the upload procedure fails somehow but the image still gets uploaded.
>> The codeline mentioned in the error message is $image =
>> imagecreatefromstring( file_get_contents( $file ) );
>> I can see the image in the media library and I can also attach it to
>> posts, but only in it's full size. Previously uploaded images work like they
>> should, and between the last uploaded image that works and now the only
>> change is a WP upgrade from 3.0.3 to 3.1.
>> Any hints or pointers as to what could be causing this would be helpful.
>> The support forum suggestions are not helping, neither is google...
>> I'm running WP 3.1 if it's of any interest. Sorry for the long post.
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
More information about the wp-hackers