WordPress.org

Make WordPress Core

Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#17244 closed defect (bug) (duplicate)

RSS feed not showing full text regardless of settings

Reported by: miocene22 Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.1
Component: Feeds Keywords:
Focuses: Cc:

Description

This came to my attention after a client approached me noting that the RSS feed only outputs a summary regardless of the "full text" setting in the wordpress back end.

The problem is seen in the core file: wp-includes/feed-rss2.php; line 44:

<?php if (get_option('rss_use_excerpt')) : ?>
                <description><![CDATA[<?php the_excerpt_rss() ?>]]></description>
<?php else : ?>
                <description><![CDATA[<?php the_excerpt_rss() ?>]]></description>
        <?php if ( strlen( $post->post_content ) > 0 ) : ?>
                <content:encoded><![CDATA[<?php the_content_feed('rss2') ?>]]></content:encoded>
        <?php else : ?>
                <content:encoded><![CDATA[<?php the_excerpt_rss() ?>]]></content:encoded>
        <?php endif; ?>
<?php endif; ?>

Instead I believe it should be:

<?php if (get_option('rss_use_excerpt')) : ?>
                <description><![CDATA[<?php the_excerpt_rss() ?>]]></description>
<?php else : ?>
                <description><![CDATA[<?php the_content_feed('rss2') ?>]]></description>
        <?php if ( strlen( $post->post_content ) > 0 ) : ?>
                <content:encoded><![CDATA[<?php the_content_feed('rss2') ?>]]></content:encoded>
        <?php else : ?>
                <content:encoded><![CDATA[<?php the_excerpt_rss() ?>]]></content:encoded>
        <?php endif; ?>
<?php endif; ?>

Change History (3)

#1 @kawauso
5 years ago

From my background reading, it's a matter of contention whether <description> should contain the synopsis or full content.

Opera 11 and Internet Explorer 9 both use <content:encoded> if it exists, while Firefox 4 does not. Google Chrome has no native RSS display.

#2 @kawauso
5 years ago

  • Resolution set to duplicate
  • Status changed from new to closed

#3 @ocean90
5 years ago

  • Milestone Awaiting Review deleted
Note: See TracTickets for help on using tickets.