Add custom post type to RSS feed
-
Hi
I have several custom post types. I used the plugin CustomPress from WPMUDEV.
Today I mentioned that the custom post types are not displayed in my RSS feed. The RSS feed is completely empty because all my entries are custom post types.
I tried two different plugins and also this code in my child-theme’s function.php but nothing worked:
function my_new_feed($qv) {
if (isset($qv[‘feed’]) && !isset($qv[‘post_type’]))
$qv[‘post_type’] = array(‘buecher’, ‘news’, ‘interviews’, ‘artikel’);
return $qv;
}
add_filter(‘request’, ‘my_new_feed’);Did I something wrong with this code? Do I have to replace the “my_new_feed” with another term of my blog?
The feed URL I use is https://www.mydomain.com/feedThats correct, right?
Can somebody please help me. I am really sad about that because I have a quit good running little blog with a RSS feed which doesn’t work ??
- The topic ‘Add custom post type to RSS feed’ is closed to new replies.