rss_widget_feed_link filter-hookWP 5.9.0

Filters the classic RSS widget's feed icon link.

Themes can remove the icon link by using add_filter( [rss_widget_feed_link](/hook/rss_widget_feed_link),'__return_false');.

Usage

add_filter( 'rss_widget_feed_link', 'wp_kama_rss_widget_feed_link_filter', 10, 2 );

/**
 * Function for `rss_widget_feed_link` filter-hook.
 * 
 * @param string $feed_link HTML for link to RSS feed.
 * @param array  $instance  Array of settings for the current widget.
 *
 * @return string
 */
function wp_kama_rss_widget_feed_link_filter( $feed_link, $instance ){

	// filter...
	return $feed_link;
}
$feed_link(string)
HTML for link to RSS feed.
$instance(array)
Array of settings for the current widget.

Changelog

Since 5.9.0 Introduced.

Where the hook is called

WP_Widget_RSS::widget()
rss_widget_feed_link
wp-includes/widgets/class-wp-widget-rss.php 111
$feed_link = apply_filters( 'rss_widget_feed_link', $feed_link, $instance );

Where the hook is used in WordPress

Usage not found.