Home Forums WoodMart support forum Stop Generating Image Sizes Reply To: Stop Generating Image Sizes

#147383

Artem Temos
Keymaster

Hi,

Try to add the following PHP code snippet to the child theme functions.php file to do this

function unset_image_sizes( $sizes ) {
    unset( $sizes['thumbnail'] );
    unset( $sizes['medium'] );
    unset( $sizes['large'] );
    unset( $sizes['medium_large'] );
    unset( $sizes['woodmart_shop_catalog_x2']) ;
    unset( $sizes['woocommerce_thumbnail'] );
    unset( $sizes['woocommerce_single'] );
    unset( $sizes['woocommerce_gallery_thumbnail'] );
    unset( $sizes['shop_catalog'] );
    unset( $sizes['shop_single'] );
    unset( $sizes['shop_thumbnail'] );
    return $sizes;
}
add_filter('intermediate_image_sizes_advanced', 'unset_image_sizes');

Regards