wp_video_shortcode_class хук-фильтрWP 3.6.0

Filters the class attribute for the video shortcode output container.

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

add_filter( 'wp_video_shortcode_class', 'wp_kama_video_shortcode_class_filter', 10, 2 );

/**
 * Function for `wp_video_shortcode_class` filter-hook.
 * 
 * @param string $class CSS class or list of space-separated classes.
 * @param array  $atts  Array of video shortcode attributes.
 *
 * @return string
 */
function wp_kama_video_shortcode_class_filter( $class, $atts ){

	// filter...
	return $class;
}
$class(строка)
CSS class or list of space-separated classes.
$atts(массив)
Array of video shortcode attributes.

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

С версии 3.6.0 Введена.
С версии 4.9.0 The $atts parameter was added.

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

wp_video_shortcode()
wp_video_shortcode_class
wp-includes/media.php 3594
$atts['class'] = apply_filters( 'wp_video_shortcode_class', $atts['class'], $atts );

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

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