Topic on Project:Support desk

[RESOLVED] Memory Error When Trying To Upload Image To Wiki

3
Seedier Wiki (talkcontribs)

Mediawiki 1.16.4, PHP 5.3.25, SQL 5.5.32

Am trying to upload an image file to my Mediawiki. It's a .png file, 6012px x 1153px and weighs in at 202KB. I've uploaded 'large' images before without a problem. On this occasion, I get the following error.

Fatal error: Allowed memory size of 52428800 bytes exhausted (tried to allocate 20795508 bytes) in /home/locallan/public_html/includes/media/Bitmap.php on line 213

Advice would be welcome.

MarkAHershberger (talkcontribs)

Please upgrade to at least 1.19.

You need to increase your allowed memory size. Try adding

ini_set('memory_limit', '128M');

to your LocalSettings.php.

Seedier Wiki (talkcontribs)

Thank you. Before changing anything else, I reduced the 'physical' width of the .png file by 1000px and tried again to upload it. As is often the illogical case with images, the file size increased five fold to around 1MB but the image uploaded without difficulty. Unless I read of a major problem associated with retaining Mediawiki 1.16.4, I will do so for the time being. So I suppose this is resolved.

Reply to "[RESOLVED] Memory Error When Trying To Upload Image To Wiki"