Featured Image to RSS Feed
function featuredtoRSS($content) {
global $post;
if ( has_post_thumbnail( $post->ID ) ){
$content = '<div>' . get_the_post_thumbnail( $post->ID, 'medium', array( 'style' => 'margin-bottom: 15px;' ) ) . '</div>' . $content;
}
return $content;
}
add_filter('the_excerpt_rss', 'featuredtoRSS');
add_filter('the_content_feed', 'featuredtoRSS');
add the above code to your functions.php, its located in your theme folder,
how to navigate there;
Log on to your cPanel, file manager, root folder (usually "public_html"), wp-content, themes, functions.php
note: this method is best is you are using child theme,Â
Â
there are quite few plugins out there which can be used to add functions to fucntions.php without going to your hosing or cPlanel.
I recommend to "Code Snippet" it worked fine for me on multiple websitesÂ