self::CLASS_NAME, 'customize_selective_refresh' => true, 'description' => __( 'Videos and embeds from YouTube, SlideShare, Spotify, and more.', 'adapter-responsive-video' ), ) ); } /** * Outputs the widget form. * * @param array $instance Widget data. * @return void */ public function form( $instance ) { $video_url = isset( $instance[ self::VIDEO_URL_KEY ] ) ? $instance[ self::VIDEO_URL_KEY ] : ''; ?>
get_iframe_attributes( $raw_embed_markup ); $instance['video_source'] = $iframe_attributes['src']; $instance['aspect_ratio_class'] = $iframe_attributes['class']; $has_iframe = preg_match( '/^