oembed_min_max_width filter-hookWP 4.4.0

Filters the allowed minimum and maximum widths for the oEmbed response.

Usage

add_filter( 'oembed_min_max_width', 'wp_kama_oembed_min_max_width_filter' );

/**
 * Function for `oembed_min_max_width` filter-hook.
 * 
 * @param array $min_max_width Minimum and maximum widths for the oEmbed response.
 *
 * @return array
 */
function wp_kama_oembed_min_max_width_filter( $min_max_width ){

	// filter...
	return $min_max_width;
}
$min_max_width(array)

Minimum and maximum widths for the oEmbed response.

  • min(int)
    Minimum width.
    Default: 200

  • max(int)
    Maximum width.
    Default: 600

Changelog

Since 4.4.0 Introduced.

Where the hook is called

get_oembed_response_data()
oembed_min_max_width
wp-includes/embed.php 571-577
$min_max_width = apply_filters(
	'oembed_min_max_width',
	array(
		'min' => 200,
		'max' => 600,
	)
);

Where the hook is used in WordPress

Usage not found.