wp_video_shortcode_class filter-hookWP 3.6.0

Filters the class attribute for the video shortcode output container.

Usage

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(string)
CSS class or list of space-separated classes.
$atts(array)
Array of video shortcode attributes.

Changelog

Since 3.6.0 Introduced.
Since 4.9.0 The $atts parameter was added.

Where the hook is called

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

Where the hook is used in WordPress

Usage not found.