admin管理员组

文章数量:1426975

I'm trying to add a class lazyload and the data-src attribute to my product images (woocommerce). I've look everywhere and couldn't find a solution for this.

I've try with some plugins, like a3 lazyload, but it does not work with the product images.

Thank you in advance,

I'm trying to add a class lazyload and the data-src attribute to my product images (woocommerce). I've look everywhere and couldn't find a solution for this.

I've try with some plugins, like a3 lazyload, but it does not work with the product images.

Thank you in advance,

Share Improve this question asked Mar 20, 2019 at 14:06 ChefussChefuss 231 silver badge6 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 1

Are you using a theme that has WooCommerce support? Look for:

woocommerce_get_product_thumbnail

and replace it with

the_post_thumbnail

This has worked before for me with A3 Lazy Load plugin.

本文标签: woocommerce image product add a class and datasrc attributes