Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webp - Your PHP version is compiled without WebP support. #1322

Closed
maraism opened this issue Dec 23, 2020 · 3 comments
Closed

Webp - Your PHP version is compiled without WebP support. #1322

maraism opened this issue Dec 23, 2020 · 3 comments

Comments

@maraism
Copy link

maraism commented Dec 23, 2020

Hi,

I think there is an error in Liip\ImagineBundle\DependencyInjection\Configuration.php for webp.
We need to replace :
->ifTrue(function ($v) { return !$v || function_exists('imagewebp'); })
by

->ifTrue(function ($v) { return $v && !function_exists('imagewebp'); })

Thank's !

maraism pushed a commit to maraism/LiipImagineBundle that referenced this issue Dec 23, 2020
@lsmith77
Copy link
Contributor

thank you for the PR.

I am holding off from merging as I first want to look into #1319 .. maybe you also can have a look as it relates to the just released WebP support.

@peter-gribanov
Copy link
Contributor

peter-gribanov commented Dec 27, 2020

This code breaks logic and will result in fatal error.
You enable WebP generation even though your PHP version does not support WebP generation.

Sorry for this. My mistake.

@beardedev
Copy link

The solution offered by @maraism work great for older version of bundle (in my case 2.1) 👏
Consider upgrading to 2.10 ti fix this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants