Return to Snippet

Revision: 48628
at July 6, 2011 18:50 by xavsio4


Initial Code
unction rss_post_thumbnail($content) {
global $post;
if(has_post_thumbnail($post->ID)) {
$content = '<p>' . get_the_post_thumbnail($post->ID) .
'</p>' . get_the_content();
}
return $content;
}
add_filter('the_excerpt_rss', 'rss_post_thumbnail');
add_filter('the_content_feed', 'rss_post_thumbnail');

Initial URL

                                

Initial Description

                                

Initial Title
Wordpress Add post thumbnails to RSS feed

Initial Tags
wordpress

Initial Language
PHP