PHP Fatal Error



A fatal error has occured during the attempt to resize the "https://afosants.cat/web/wp-content/uploads/2023/01/Objectiu-Afosants-n26-portada.png" image.

Possible causes and their solutions (in the order of occurence) are:

  1. Your webserver has low PHP memory limit.
    Locate "php.ini" file on your webserver and change "memory_limit" variable to at least "128MB" or ideally "256MB". If you do not know how this works, ask your hosting company to do this for you.

  2. Your webserver does not have the "GD" PHP extension installed or is using a wrong version that is incompatible with the version of PHP that your webserver is running. It is a necessary PHP extension that allows image resizing.
    Ask your hosting company to install the "GD" PHP extension on your webserver.

  3. The image that you have uploaded and tried to resize is too large. This can be stressful on your webserver.
    Reupload the image with smaller dimensions and size. We don't recommend uploading images larger than 2000x2000px and with size no more than 2MB.

  4. You are resizing the image to a very large resolution like 2000x2000px and larger. This can be stressful on your webserver.
    Do not resize images to resolutions larger than 2000x2000px.

  5. The /wp-content/uploads/freshizer/ directory does not exist on your webserver.
    Using your favorite FTP program, manually create this directory and set it's permissions to 0644.

  6. Your webserver has (almost) no disk space left.
    Double-check if there is enough free space left on your webserver disk.



Error details:

array(4) {
  ["type"]=>
  int(1)
  ["message"]=>
  string(80) "Allowed memory size of 268435456 bytes exhausted (tried to allocate 12288 bytes)"
  ["file"]=>
  string(107) "/home1/afosants/public_html/web/wp-content/plugins/fresh-framework/framework/extern/freshizer/freshizer.php"
  ["line"]=>
  int(283)
}