Skip to content

Instantly share code, notes, and snippets.

@nielslange
Last active April 6, 2019 09:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nielslange/b56f943b33ac0cbcdfb2fcb00864adf5 to your computer and use it in GitHub Desktop.
Save nielslange/b56f943b33ac0cbcdfb2fcb00864adf5 to your computer and use it in GitHub Desktop.
<?php
// Remove default image sizes.
add_action('init', 'smntcs_remove_image_sizes');
function smntcs_remove_image_sizes() {
remove_image_size( 'course_archive_thumbnail' );
remove_image_size( 'course_single_thumbnail' );
remove_image_size( 'lesson_archive_thumbnail' );
remove_image_size( 'lesson_single_thumbnail' );
remove_image_size( 'portfolio_horizontal' );
remove_image_size( 'portfolio_slider' );
remove_image_size( 'portfolio_vertical' );
remove_image_size( 'shop_catalog' );
remove_image_size( 'shop_thumbnail' );
remove_image_size( 'woocommerce_gallery_thumbnail' );
remove_image_size( 'woocommerce_single' );
remove_image_size( 'woocommerce_thumbnail' );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment