A WordPress-centric search engine for devs and theme authors



remove_image_size ›

Since3.9.0
Deprecatedn/a
remove_image_size ( $name )
Parameters:
  • (string) $name The image size to remove.
    Required: Yes
Returns:
  • (bool) True if the image size was successfully removed, false on failure.
Defined at:
Codex:

Remove a new image size.



Source

function remove_image_size( $name ) {
	global $_wp_additional_image_sizes;

	if ( isset( $_wp_additional_image_sizes[ $name ] ) ) {
		unset( $_wp_additional_image_sizes[ $name ] );
		return true;
	}

	return false;
}