feed_link
Filters the feed type permalink.
Usage
add_filter( 'feed_link', 'wp_kama_feed_link_filter', 10, 2 );
/**
* Function for `feed_link` filter-hook.
*
* @param string $output The feed permalink.
* @param string $feed The feed type. Possible values include 'rss2', 'atom', or an empty string for the default feed type.
*
* @return string
*/
function wp_kama_feed_link_filter( $output, $feed ){
// filter...
return $output;
}
- $output(string)
- The feed permalink.
- $feed(string)
- The feed type. Possible values include 'rss2', 'atom', or an empty string for the default feed type.
Changelog
| Since 1.5.0 | Introduced. |
Where the hook is called
feed_link
wp-includes/link-template.php 732
return apply_filters( 'feed_link', $output, $feed );