• Resolved footstepsdesign

    (@footstepsdesign)


    Hi, thanks for a really great plugin.

    Is it possible to change the thumbnail size/compression? I can’t see any settings for this so 100x100px seems to be the default.

    I wondered if there was a function I could add like if I want a custom image size:
    add_image_size('gallery_thumb', 500, 500, true);

    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author NikHiL Gadhiya

    (@nikhilgadhiya)

    Hello,
    Here is the hook for changing?image?size.?You can pass width and height based on your needs.

    // for thumbnail?image?size
    function woocommerce_gallery_thumbnail_size_callback( $args ) {
      return array(240,240,0);
    }
    add_filter( 'woocommerce_gallery_thumbnail_size', 'woocommerce_gallery_thumbnail_size_callback', 99 );
    // for main?image??size
    add_filter( 'woocommerce_get_image_size_single', 'woocommerce_get_image_size_single_callback',99);
    function woocommerce_get_image_size_single_callback( $size?) {
      return array('width' => 800, 'height' => 600, 'crop' => 1, );
    }


    Thank You.

    Thread Starter footstepsdesign

    (@footstepsdesign)

    Excellent, thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Thumbnail image size/quality’ is closed to new replies.