Home / Disable the Excerpt in RSS Feeds
Duplicate Snippet

Embed Snippet on Your Site

Disable the Excerpt in RSS Feeds

Hide the excerpt or content from your RSS feeds.

90+
Code Preview
php
<?php
// Make sure we display the excerpt in the feed.
add_filter( 'pre_option_rss_use_excerpt', '__return_true' );
// Remove the excerpt content for feeds.
add_filter( 'the_excerpt_rss', '__return_empty_string' );

Comments

Add a Comment