wp_get_missing_image_subsizes


wp_get_missing_image_subsizes ( $attachment_id )

Parameters:
  • (int) $attachment_id The image attachment post ID.
Returns:
  • (array) An array of the image sub-sizes that are currently defined but don't exist for this image.
Defined at:

Description

Compare the existing image sub-sizes (as saved in the attachment meta) to the currently registered image sub-sizes, and return the difference.

Registered sub-sizes that are larger than the image are skipped.

Related Functions

wp_get_registered_image_subsizes, wp_get_additional_image_sizes, wp_create_image_subsizes, wp_get_attachment_image_sizes, wp_update_image_subsizes

Top Google Results

User discussions

wpseek mobile