• Resolved segmant

    (@segmant)


    As the title says, WebP images dont display as Product images. I replaced only 2 and they dont show

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Are they gallery images? I ask because the featured image for the product itself is a jpg.

    I did just test this myself using a sample webp image and it certainly does not work like I might expect but the image is output as it should be:

    The problem with the display is that the HTML is output with a height and width of 1 px and if I had to guess, I would guess that is because there is no way for WooCommerce (or probably WordPress for that matter) to determine the size of the image.

    If I tweak the height/width attributes the image is displayed as expected though.

    FWIW, webp image sizing doesn’t seem to work with regular WordPress posts either so I don’t feel that this is really a problem inherent to WooCommerce but more likely a limitation of WordPress in its current iteration.

    Given that one must add a filter to even enable the webp mime type to be uploaded to the media library, it seems that these types of images aren’t fully supported within WordPress even though they may work in certain instances.

    You might consider opening an issue on the WooCommerce github repo here: https://github.com/woocommerce/woocommerce/issues though I’m not certain that would yield any immediate results

Viewing 1 replies (of 1 total)
  • The topic ‘WebP Featured Images dont work’ is closed to new replies.