Skip to content

Instantly share code, notes, and snippets.

@fahdi
Created November 16, 2013 16:52
Show Gist options
  • Save fahdi/7502414 to your computer and use it in GitHub Desktop.
Save fahdi/7502414 to your computer and use it in GitHub Desktop.
<?php
/**
* Plugin Name: Update WP feed to feedburner
* Plugin URI: http://www.wpquestions.com/question/showLoggedIn/id/8997
* Description: Update WP feed URL to feedburner URL
* Version: 0.1
* Author: Fahd Murtaza
* Author URI: http://www.fahdmurtaza.com
* License: GPL2
*/
// replace the default posts feed with feedburner
function appthemes_custom_rss_feed( $output, $feed ) {
if ( strpos( $output, 'comments' ) )
return $output;
return esc_url( 'http://feeds.feedburner.com/ChangeToYourThemeURL/' );
}
add_action( 'feed_link', 'appthemes_custom_rss_feed', 10, 2 );
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment