Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Custom RSS for WordPress
add_action( 'after_setup_theme', 'rss_template' );
* Register custom RSS template.
function rss_template() {
add_feed( 'media', 'custom_rss' );
* Custom RSS template callback.
function custom_rss() {
get_template_part('partials/feed', 'attachments');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.