public/class-dynamic-image-resizer-public.php
public function get_sizes( $size = '' ) {
		global $_wp_additional_image_sizes;
		$sizes = array();
		$get_intermediate_image_sizes = get_intermediate_image_sizes();

		// Create the full array with sizes and crop info.
		foreach ( $get_intermediate_image_sizes as $_size ) {
			if ( in_array( $_size, array( 'thumbnail', 'medium', 'large' ) ) ) {
				$sizes[ $_size ]['width'] = get_option( $_size . '_size_w' );
				$sizes[ $_size ]['height'] = get_option( $_size . '_size_h' );
				$sizes[ $_size ]['crop'] = (bool) get_option( $_size . '_crop' );
			} elseif ( isset( $_wp_additional_image_sizes[ $_size ] ) ) {
				$sizes[ $_size ] = array(
					'width'		=> $_wp_additional_image_sizes[ $_size ]['width'],
					'height'	=> $_wp_additional_image_sizes[ $_size ]['height'],
					'crop'		=> $_wp_additional_image_sizes[ $_size ]['crop'],
				);
			}
		}

		// If $size argument is supplied, just return that size.
		if ( $size ) {
			if ( isset( $sizes[ $size ] ) ) {
				return $sizes[ $size ];
			} else {
				return false;
			}
		}

		return $sizes;
	}
public function get_sizes( $size = '' ) {
		global $_wp_additional_image_sizes;
		$sizes = array();
		$get_intermediate_image_sizes = get_intermediate_image_sizes();

		// Create the full array with sizes and crop info.
		foreach ( $get_intermediate_image_sizes as $_size ) {
			if ( in_array( $_size, array( 'thumbnail', 'medium', 'large' ) ) ) {
				$sizes[ $_size ]['width'] = get_option( $_size . '_size_w' );
				$sizes[ $_size ]['height'] = get_option( $_size . '_size_h' );
				$sizes[ $_size ]['crop'] = (bool) get_option( $_size . '_crop' );
			} elseif ( isset( $_wp_additional_image_sizes[ $_size ] ) ) {
				$sizes[ $_size ] = array(
					'width'		=> $_wp_additional_image_sizes[ $_size ]['width'],
					'height'	=> $_wp_additional_image_sizes[ $_size ]['height'],
					'crop'		=> $_wp_additional_image_sizes[ $_size ]['crop'],
				);
			}
		}

		// If $size argument is supplied, just return that size.
		if ( $size ) {
			if ( isset( $sizes[ $size ] ) ) {
				return $sizes[ $size ];
			} else {
				return false;
			}
		}

		return $sizes;
	}
public function get_sizes ( $ size = '' ) { global $ _wp_additional_image_sizes ; $ sizes = array ( ) ; $ get_intermediate_image_sizes = get_intermediate_image_sizes ( ) ; // Create the full array with sizes and crop info. foreach ( $ get_intermediate_image_sizes as $ _size ) { if ( in_array ( $ _size , array ( 'thumbnail' , 'medium' , 'large' ) ) ) { $ sizes [ $ _size ] [ 'width' ] = get_option ( $ _size . '_size_w' ) ; $ sizes [ $ _size ] [ 'height' ] = get_option ( $ _size . '_size_h' ) ; $ sizes [ $ _size ] [ 'crop' ] = ( bool ) get_option ( $ _size . '_crop' ) ; } elseif ( isset ( $ _wp_additional_image_sizes [ $ _size ] ) ) { $ sizes [ $ _size ] = array ( 'width' => $ _wp_additional_image_sizes [ $ _size ] [ 'width' ] , 'height' => $ _wp_additional_image_sizes [ $ _size ] [ 'height' ] , 'crop' => $ _wp_additional_image_sizes [ $ _size ] [ 'crop' ] , ) ; } } // If $size argument is supplied, just return that size. if ( $ size ) { if ( isset ( $ sizes [ $ size ] ) ) { return $ sizes [ $ size ] ; } else { return false ; } } return $ sizes ; }
Get all the currently defined named image sizes

@since  1.0.0
@param  string $size If supplied, only return this size.
@return array        Image sizes
Get all the currently defined named image sizes