0

How can I add specific pages content to my sites RSS feed? As of right now the RSS feed automatically displays all of the sites posts content, but I want to add the RSS functionality to certain pages as well. Is there any way of doing this? Thank you.

1
  • RSS isn’t really for static content. It’s intended for a feed of updating content. Why do you need to add pages to it? Commented Jun 11, 2019 at 16:39

1 Answer 1

0

This is tested and works but you may get unexpected results.

function wpse_rss_pages($qv){
    $rss_feed = array('post', 'page');
    if(isset($qv['feed']) && !isset($qv['post_type']))
        $qv['post_type'] = $rss_feed;
    return $qv;
}

add_filter('request', 'wpse_rss_pages');

You could also seperate the feed by doing something like THIS.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.