Background image not using webp on certain pages
-
Report number: YDAWMEUE
Hello,
I’m currently having an issue with background images. I’m using Grid Builder, a plugin to create filterable grids. I’m using it to show products created with WooCommerce. The cards are rendered using a background-image. However, I don’t understand why on some pages they will correctly use the webp version of the image but in other pages they won’t. The HTML structure look the same for those background images (with a little difference I’m describing below).
I tried :
– Purging the cache
– Disabled/Enabling again LiteSpeed LsCache in Cpanel
– Disabling the plugin (but then everything is going back to .jpg)
– Disabling and enabling again the WebP replacement.I also noticed something, the background images in the grids I’m using in my home page (everything works here) look like that:
background-image:url(https://example.com/wp-content/uploads/2022/02/example.jpg.webp)
But in any other page using a grid it looks like that:
background-image: url("https://example.com/wp-content/uploads/2022/01/example.jpg");
I noticed the second version is using
" "
, I’m not sure if this is the reason why it doesn’t work.The problem could also be coming from Grid Builder but previously I used ShortPixel (I uninstalled it and cleanly removed all the files related to it, after that I switched to Quic.Cloud, and I also restored all the images to the original ones before doing so) and the .webp files were correctly used for the grids in all my pages.
Also, another weird issue, on certain pages, in the source panel, the images will be shown as ‘Webp’ images despite having
.jpg
and not.jpg.webp
in their slug.
(I’m still talking only about background images here). On other pages, there will be shown as .jpg everywhere (slug included). Purging all the caches I could think about didn’t solve that.I’m not sure what else I could do to make it work,
Best regards,
Oshika
- The topic ‘Background image not using webp on certain pages’ is closed to new replies.