-
Notifications
You must be signed in to change notification settings - Fork 110
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
Image mime type is not set correctly when a webp
image is generated.
#67
Comments
@mitogh Similar to #69, this may be because the source image is still JPEG if it was originally JPEG. Try uploading a WebP image directly, in that case it should say |
The mime type in the media library should show the mime type of the image you uploaded - the original image, not the mime type of the sub sizes (of which there could be potentially more than one) which is what the webp-uploads module changes. So if your original image is a jpeg, this should show |
Uploading a
Agree with this behavior, however, the behavior is not consistent when a Questions / Needs decision
This is closely related to #96 (comment) DescriptionScenario 1 - Very large imageWhen a large (in dimensions) image is uploaded to WordPress (see Image 1 at the bottom), WordPress would create a subsize with the suffix Discrepancy between URL from full image size and mime type in the adminThe Full URL from the editor would be This behavior is correctly displayed on the single view of the media, where both displays the correct mime type WebP for the URL and the UI. The original image (very large image in JPEG format) is uploaded as well and stored in the same directory as the This is the current behavior in WordPress with the difference when the module is enabled t Meta information of the image
See:
Scenario 2 - Small imageWhen a smaller image is uploaded the URL of the image Metadata of the image
InconsistenciesAs described above the module for WebP works as expected but I'm not 100% if the current behavior is intended due to this behavior being inconsistent when different image sizes are uploaded, the main idea/question is to define the path we want to implement for the ResourcesImage 1Image 2 |
Just tested this fix and works as expected @adamsilverstein 👍 |
Note
Make sure the
Performance
plugin is enabled and activated, as well with thewebp
modules for images at:Settings > Performance
Related with issue:
Steps to recreate:
Media > Add New
Media > Library
and open the image, observe the image has an extensionimage/jpeg
instead ofimage/webp
Original image to replicate the issue.
The text was updated successfully, but these errors were encountered: