Several articles, including this discussion and this tutorial, explain how to add custom post types to the main WordPress RSS feed. None of the suggested methods worked for me with WordPress 3.5.1, so I created another solution with a more careful check of the post types already included in the feed:
function kc_customs2RSS($qv) {
if(isset($qv['feed'])) {
if(!isset($qv['post_type'])) {
$qv['post_type'] = array('mytype', 'post');
} else {
if(!in_array('mytype', $qv['post_type'])) $qv['post_type'][] = 'mytype';
if(!in_array('post', $qv['post_type'])) $qv['post_type'][] = 'post';
}
}
return $qv;
}
add_filter('request', 'kc_customs2RSS');
Because this is standard PHP code, you can place it in your theme's functions.php file, in a PHP file inside the mu-plugins directory, or in your own plugin. Create the mu-plugins directory if it does not already exist. I hope this saves you some time.
