wpseek.com
Bazujące na WordPress narzędzie wyszukiwania dla deweloperów i twórców motywów.



has_image_size › WordPress Function

Od3.9.0
Przestarzałyn/a
has_image_size ( $name )
Parametry:
  • (string) $name The image size to check.
    Wymagane: Tak
Powrót:
  • (bool) True if the image size exists, false if not.
Zdefiniowane na:
Codex:

Checks if an image size exists.



Źródło

function has_image_size( $name ) {
	$sizes = wp_get_additional_image_sizes();
	return isset( $sizes[ $name ] );
}