• Resolved pomegranates

    (@pomagaj)


    Hello, first of all, thanks for making this great plugin.

    I’m using image preloader on my site. This image is in apng format. After png conversion this particular apng image is no longer visible on my site. It’s not showing up on Firefox, Chrome or Edge. Is there a way to exclude files individually? Or maybe you could introduce apng exclusion? I know I could remove this file from media uploads to exclude it from conversion but is there another way to do it?

    Thanks in advance.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Mateusz Gbiorczyk

    (@mateuszgbiorczyk)

    Hi @pomagaj,

    Thank you for your message. I will try to help you.

    Nice to meet you.

    Can you send me an example of this file?

    Thread Starter pomegranates

    (@pomagaj)

    Plugin Author Mateusz Gbiorczyk

    (@mateuszgbiorczyk)

    Thank you.

    Verifying all files and checking if they are animated would be too burdensome, so I didn’t implement this solution. If there is a better way, I will try to implement it.

    At this moment, I have a different solution for you. Please try to delete all regenerated images at this time.

    Then add the following filter to your code (using the correct file name):

    add_filter('webpc_attachment_paths', function($paths)
    {
      if (!isset($paths['_source']) || (strpos($paths['_source'], '/preloader-manufaktury.png') === false)) {
        return $paths;
      } else {
        return [];
      }
    });

    And then regenerate your images. This particular one will be omitted.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘APNG support…? Is there a way to exclude images individually?’ is closed to new replies.