I am not a fan of running a large amount of plugins on my WordPress sites. Even though there has been a lot of debate as to whether or not it actually effects the performance of your site, I would rather limit the number by as many as possible. For those of you that have looked for a quick and easy way to redirect your feeds to FeedBurner, you may have downloaded and installed a few different plugins. Well, you don’t need a plugin, just edit your functions.php file and redirect away.
To redirect your feed without a plugin, add the following to your theme’s functions.php file and replace the URL with your own FeedBurner URL
[php] // ————————————————————————–// Start Redirect Feed to FeedBurner
// ————————————————————————–
function custom_rss_feed( $output, $feed ) {
if ( strpos( $output, ‘comments’ ) )
return $output;
return esc_url( ‘http://feeds.feedburner.com/yourfeedburnerurl’ );
}
add_action( ‘feed_link’, ‘custom_rss_feed’, 10, 2 );
// ————————————————————————–
// End Redirect Feed to FeedBurner
// ————————————————————————–
[/php]