Support » Plugin: WooCommerce » Product thumbnail size not editable after last update

  • Resolved dav74


    Hi there,

    Can you please tell me how you update the product thumbnail sizes now, since your 3.3 update? Previously this was so well done, in image settings. Now it appears you have removed this basic functionality.

    In the Customize > WooCommerce > Product Images, there is no option for the product image thumbnails sizing (only for the category thumbnails).

    Since your latest update (3.3.2) my product image thumbnails have changed size and completely distorted. There is no height attribute anymore, so they display as squares which they should not.

Viewing 15 replies - 16 through 30 (of 36 total)
  • rockytt


    OK – still not 100% clear here – where does this code go?

    add_filter( ‘woocommerce_gallery_thumbnail_size’, ‘custom_woocommerce_gallery_thumbnail_size’ );

    function custom_woocommerce_gallery_thumbnail_size() {
    return ‘thumbnail’;

    (I too am sad about the change – worked great before and we had full control)

    Thread Starter dav74


    @nick8182 Hi Nick. Actually my issue is not completely fixed as the new WooCommerce templating has caused issues with the “Yith Badges” plugin. Are you using “Yith Badges” at all? If so, I thought that might be where your issue is. I am trying to get them to sort it but so far they have not found a solution.



    Where to add this code?

    add_filter( ‘woocommerce_gallery_thumbnail_size’, ‘custom_woocommerce_gallery_thumbnail_size’ );

    function custom_woocommerce_gallery_thumbnail_size() {
    return ‘thumbnail’;

    Thread Starter dav74


    @sebastian1611 The safest is possibly to download the “code snippets” plugin, and add it via that. It avoids having to manually update the functions.php file (because that is where it needs to be added).

    yeah – no love even after updating functions.php – still pulling the old thumbnail (

    I’m even using a woocommerce theme just to avoid this kind of situation. Why in the world would an “update” only allow us to adjust image sizes in 2 of the 3 places they appear in their own store??

    The question;
    Can you please tell me how you update the product thumbnail sizes now, since your 3.3 update? Previously this was so well done, in image settings. Now it appears you have removed this basic functionality.

    I just need square cropped thumbnail on a single product page. This issue tells me it is solved. But I just can’t see where there is a solution.

    Please help me out, how can I get square thumbnails?

    Thread Starter dav74


    Hi @edwindekuiper

    Woocommerce automatically outputs a square thumbnail image. You then use CSS to chnge the size. If you do not have square thumbnail images, then you must have some CSS which is affecting the thumbnail size / format.

    Check with your theme developer is my advice.

    Hi Dav74,

    yes I did. The reaction of Select Themes was to look in

    But I’m a designer/webmaster not a programmer.

    I placed this code in my child theme function.php
    add_filter( ‘woocommerce_get_image_size_gallery_thumbnail’, function( $size ) {
    return array(
    ‘width’ => 200,
    ‘height’ => 200,
    ‘crop’ => 1,
    } );

    It doesn’t work.

    Regenerate thumbnails gave this value:
    woocommerce_thumbnail: 300×300 pixels (cropped to fit)
    woocommerce_gallery_thumbnail: 200×200 pixels (cropped to fit)

    in the css:
    .woocommerce .product .images.woocommerce-product-gallery–columns-4 :not(:first-child).woocommerce-product-gallery__image {
    width: 33.33%;
    padding-top: 6px;
    padding-right: 3px;

    Stil, the images are not square:

    is there someone to help?

    Thread Starter dav74



    I possibly cannot help you any further than that, as I too am a designer rather than developer!

    Hello everyone – I have same problem since last update and got a mess now.. Tried all above solutions without success. Any hint, tip to help us further?

    @edwindekuiper,you have a very similar problem as most of the people here updating to 3.3 ,this issue broke entirely my site,makes me downgrade to 3.0.

    There is no fix here,I’ve tried them all,just like you

    put this line in your theme functions.php.

    $our_html .= wp_get_attachment_image( $attachment_id, ‘woocommerce_thumbnail’, false, $attributes );

    and put the template product-thumbnails.php from the GIT woo vers 3.3 , in the folder on your server
    your theme/woocomerce / single product /
    or from your woocomerce plugin folder.

    Previously theme had

    $our_html .= wp_get_attachment_image( $attachment_id, ‘shop_single’, false, $attributes );

    So this thumnails.php was introduced into the new version, so themes became obsolete with thumbnails settings.

    thanks, but unfortunately no success.

    product-thumbnails.php is quite empty…
    // Note: wc_get_gallery_image_html was added in WC 3.3.2 and did not exist prior. This check protects against theme overrides being used on older versions of WC.
    if ( ! function_exists( ‘wc_get_gallery_image_html’ ) ) {

    Can someone dumb this down even further? I see all this “just put this code here”, but I don’t even know where “here” is. I don’t have square thumbnails. They are not the same size.

    Thank you in advance for any input for those of us that are pre-dummy. All these codes make absolutely no sense to me. For instance, I don’t know where theme function php is.

Viewing 15 replies - 16 through 30 (of 36 total)
  • The topic ‘Product thumbnail size not editable after last update’ is closed to new replies.