Add the_feed_link(). fixes #11794, props sirzooro.

git-svn-id: https://develop.svn.wordpress.org/trunk@13557 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2010-03-02 19:00:21 +00:00
parent be0e181e96
commit e7c35109d6
1 changed files with 13 additions and 0 deletions

View File

@ -397,6 +397,19 @@ function get_day_link($year, $month, $day) {
}
}
/**
* Display the permalink for the feed type.
*
* @since 3.0.0
*
* @param string $anchor The link's anchor text.
* @param string $feed Optional, defaults to default feed. Feed type.
*/
function the_feed_link( $anchor, $feed = '' ) {
$link = '<a href="' . esc_url( get_feed_link( $feed ) ) . '">' . $anchor . '</a>';
echo apply_filters( 'the_feed_link', $link, $feed );
}
/**
* Retrieve the permalink for the feed type.
*