load_default_embeds хук-фильтрWP 2.9.0

Filters whether to load the default embed handlers.

Returning a falsey value will prevent loading the default embed handlers.

Использование

add_filter( 'load_default_embeds', 'wp_kama_load_default_embeds_filter' );

/**
 * Function for `load_default_embeds` filter-hook.
 * 
 * @param bool $maybe_load_embeds Whether to load the embeds library.
 *
 * @return bool
 */
function wp_kama_load_default_embeds_filter( $maybe_load_embeds ){

	// filter...
	return $maybe_load_embeds;
}
$maybe_load_embeds(true|false)
Whether to load the embeds library.
По умолчанию: true

Список изменений

С версии 2.9.0 Введена.

Где вызывается хук

wp_maybe_load_embeds()
load_default_embeds
wp-includes/embed.php 201
if ( ! apply_filters( 'load_default_embeds', true ) ) {

Где используется хук в WordPress

Использование не найдено.