wpseek.com
A WordPress-centric search engine for devs and theme authors



_oembed_filter_feed_content › WordPress Function

Since4.4.0
Deprecatedn/a
_oembed_filter_feed_content ( $content )
Access:
  • private
Parameters:
  • (string) $content The content to filter.
    Required: Yes
Returns:
  • (string) The filtered content.
Defined at:
Codex:

Prepare the oembed HTML to be displayed in an RSS feed.



Source

function _oembed_filter_feed_content( $content ) {
	$p = new WP_HTML_Tag_Processor( $content );
	while ( $p->next_tag( array( 'tag_name' => 'iframe' ) ) ) {
		if ( $p->has_class( 'wp-embedded-content' ) ) {
			$p->remove_attribute( 'style' );
		}
	}
	return $p->get_updated_html();
}