Filter for wp_embed_handler_youtube not working
In Wordpress 4.0, if I create a new post and paste a YouTube link directly into the post editor, Wordpress will automatically convert it to a YouTube embed tag. I'm trying to edit the default output for the embed tag with a filter function.
I have a snippet set up like this:
add_action( 'wp_embed_handler_youtube', 'bigger_youtube_embeds', 10, 4);
function bigger_youtube_embeds($embed, $attr, $url, $rawattr) {
// alter the $embed string...
return $embed;
}
I tried this after viewing the following documentation: https://developer.wordpress.org/reference/hooks/wp_embed_handler_youtube/
My filter function never runs, though, and I'm not even sure when it is supposed to run.