Advertisement:

Author Topic: Error when uploading images >5mb  (Read 760 times)

PaulBoss

  • Newbie
  • *
  • Posts: 2
Error when uploading images >5mb
« on: March 02, 2016, 09:55:41 am »
Hi everyone,
Often when I (or my website users) try to upload pictures with dimensions > 5MB I get a fatal error and the pictures aren't included in the ads and i get the error
"Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 48848897 bytes) in /home/........../public_html/oc-includes/osclass/classes/ImageResizer.php on line 75". The error occurs after clicking the publish ad button or in oc-admin panel when trying to update an ad with images.

_CONEJO

  • Administrator
  • Hero Member
  • *****
  • Posts: 4689
Re: Error when uploading images >5mb
« Reply #1 on: March 02, 2016, 10:26:28 am »
Please check "Imagick" instead of GD in the admin panel  > media > settings, additionally you could configure more RAM for your server

teseo

  • Hero Member
  • *****
  • Posts: 6169
Re: Error when uploading images >5mb
« Reply #2 on: March 02, 2016, 12:46:09 pm »
Hi,

If you are unable to do what _CONEJO recommends, there's this plugin to stop that from happening:

http://market.osclass.org/plugins/miscellaneous/pre-resize-images_496

Regards