-
Copy
/wp-includes/feed-rss2.php
to your theme folder -
Edit it and make whatever changes you desire (e.g. removing the line for
dc:creator
) -
in your theme’s
functions.php
file, add the following function:
remove_all_actions( 'do_feed_rss2' );
function create_my_custom_feed() {
load_template( TEMPLATEPATH . '/feed-rss2.php');
}
add_action('do_feed_rss2', 'create_my_custom_feed', 10, 1);
Edit by Otto: While that will work, this would be a better way:
function create_my_custom_feed() {
load_template( TEMPLATEPATH . '/feed-rss2.php');
}
add_feed('rss2', 'create_my_custom_feed');
The add_feed()
function is smart, and will handle the actions and such for you.
Note: It will require a one-time use of flush_rules()
to take effect.