Display a Full Article in Your Email

Many customers display a full article of content in their automated emails as seen below.

This requires a few extra considerations.

  1. Your RSS feed must contains the full article content. This will be in the <content> tag of your RSS feed.

  2. Your email code must use the [[post.post_content]] token. This accesses the full article contained in the <content> xml. It also keeps the incoming html intact. For now this is what you want.

  3. FeedOtter has created a few special filters to help process incoming HTML and images and prevent them from breaking your responsive emails. So, instead of using the vanilla post_content token we recommend the following:

[[post.post_content | cleanImages | striptags('<p><br><span><a><div><b><strong><i><em><img>') ]]

/*
Here is the breakdown:
- post_content = fetches the full article content as found in your RSS feed's <content> node.
- cleanImages = this is a special Filter that adjusts the width and height properties on any incoming images so that they won't break your email's responsiveness.  
- stripTags = another filter that removes all but the most basic HTML. This reduces the chance that some HTML from your website breaks your email.
*/

Disclaimer

While we've assisted many customers without problems it is important to:

  • Combining non-email-tested HTML in HTML emails is risky.

  • Content from your RSS feed can affect email structure.

  • Do not skip testing.

  • Use FeedOtter's test feature to send email samples to Litmus or another testing tool for verification.

Last updated