feed_link
Filters the feed type permalink.
Description
Parameters (2)
- 0. $output (string)
- The feed permalink.
- 1. $feed (string)
- Feed type.
Usage
- To run the hook, copy the example below.
- $output = apply_filters( 'feed_link', $output, $feed );
- if ( !empty( $output ) ) {
- // everything has led up to this point...
- }
- The following example is for adding a hook callback.
- // define the feed_link callback
- function filter_feed_link( $output, $feed ) {
- // make filter magic happen here...
- return $output;
- };
- // add the filter
- add_filter( 'feed_link', 'filter_feed_link', 10, 2 );
- To remove a hook callback, use the example below.
- // remove the filter
- remove_filter( 'feed_link', 'filter_feed_link', 10, 2 );
Defined (1)
The filter is defined in the following location(s).
- /wp-includes/link-template.php
- return apply_filters( 'feed_link', $output, $feed );