How to remove site link from each post in RSS feed / modify output of the_excerpt_rss()?

I’m trying to tailor an RSS feed so that it can be used to generate a newsletter via Digesto/Marketo. I’ve tried adding a custom RSS template to the site’s theme – and it worked – but I can’t seem to lose the site link that is added below each post. The post links are really all we need.

The link is being inserting just inside of the closing description tag. The code in my template that adds the description is:

<description><![CDATA[<?php the_excerpt_rss(); ?>]]></description>

My RSS template is a variation of wp-includes/feed-rss2.php, which uses the same code snippet.

There doesn’t seem to be a way to edit the output of the_excerpt_rss – if that’s even the culprit. Any help would be greatly appreciated!

2 Answers
2

After doing a search of all folders in the site for “the_excerpt_rss”, I found a Yoast plugin file that was adding the link to each post item. In the end it was as simple as accessing a field via the dashboard > SEO > advanced and clicking the RSS tab. I emptied the field “Content to put after each post in the feed”, refreshed the feed, and the link was gone. I can’t believe it was as simple as that…

Leave a Comment