Add a Blog Post to Any Campaign

This feature requires Manager user level or higher.

With MailChimp's *|FEED|* merge tags, you can include blog posts from any RSS feeds in any of your campaigns. If you use *|FEED|* tags in an  RSS-driven campaign, we'll embed additional blog content to your scheduled RSS campaigns.

Below, you'll learn how to use and customize *|FEED|* merge tags in your campaigns.

Add Feed in a Campaign

To enter a blog post into your campaign content, type this tag into any the text editor of any content block on the  Design step of the Campaign Builder. Add any other content or images around the tags, as you normally would.
Here's what the FEED tag should look like, after you add a URL and parameters for the blog entries. In this example, we're asking the campaign to display two entries from the MailChimp blog RSS feed. 

*|FEED:http://www.mailchimp.com/blog/feed/[$count=2]|*

In the text editor, you'll place that code anywhere you want the blog entries to appear. 

Important Variables

FEED merge tags must include the URL where blog's RSS feed is located. Additional variables are optional, and indicate how to format each entry in your campaign.

  • In this example, the URL is http://www.mailchimp.com/blog/feed/.
  • $count=2 indicates how many blog posts to show in the campaign. Replace the "2" with your preferred number.
  • $content=full  tells the feed to display the full blog post. 
  • $content=titles tells the feed to display the titles of each entry only, formatted as links to full content. 

If you choose to use more than one of these, format your feed like the example below. 

*|FEED:http://www.mailchimp.com/blog/feed/[$count=2,$content=titles]|*

Example MailChimp blogs included with FEED tag

To include posts from multiple blogs in your campaign, place another *|FEED|* tag in the text for each blog  feed you want to pull from.

Customize your Feed

For greater control over blog content, use *|FEEDBLOCK|* merge tags to surround customized RSS feed elements. These tags indicate how many entries pull from a feed and subsequently, which feed elements to include for each entry.

To build a FEEDBLOCK, follow the steps below. 

  1. Navigate to the Design step of the Campaign Builder.
  2. Click to edit any content block.
  3. In the text editor, enter the tags *|FEEDBLOCK:URL|* and *|FEEDITEMS:$count=#]|* to open the feed section of your campaign. Replace "URL" with your RSS feed's URL, and replace # with the number of entries you want to show.
  4. Enter FEEDITEM tags to specify which content you want to include for each entry. 
  5. At the end of these content tags, enter the closing tags *|END:FEEDITEMS|* and *|END:FEEDBLOCK|*.

​In the end, your block might look something like this example, which tells MailChimp to embed two blog entries, and include the entry title, the date it was posted, the author, and a summary of the content presented in text, for each blog entry.

*|FEEDBLOCK:http://blog.mailchimp.com/feed|*
*|FEEDITEMS:[$count=2]|*
*|FEEDITEM:TITLE|*
*|FEEDITEM:DATE|*
*|FEEDITEM:AUTHOR|*
*|FEEDITEM:CONTENT_TEXT|*
*|END:FEEDITEMS|*
*|END:FEEDBLOCK|*

 

Feed Tags and Descriptions

Here are our feed tags and a brief description of what they do. They have to do with the RSS feed (or blog) as a whole. Copy and paste the tags you want to use into your campaign.

The title of the RSS feed

The publish date of the feed

The URL for the whole feed as a whole, if available in the feed source

The feed description, if available in the feed source

Displays the posts on your RSS feed. The default number of posts is 5.

Displays a specified number of full-content posts from the feed

Feed Item Tags and Descriptions

Below are our FEEDITEM tags and a brief description of what they do. Each FEEDITEM tag refers to a specific RSS or blog entry, which we call an "item." Copy and paste the tags you want to use into your campaign.

The title of the RSS or item

The URL for the RSS item

The publish date of the RSS item. This tag allows you to include date formatting options, which are available at php.net.

The name of the author for the RSS item, if available in the feed source

The URL for comments on your post, if available in the feed source

A comma-separated list of the categories for the RSS item. May include tags or 'posted in' information in lieu of categories.

A short summary of the RSS item content in HTML format

The full content for the RSS item in HTML format, if available in the feed source

A short summary of the RSS item content in plain-text format

The full content for the RSS item in plain-text format, if available in the feed source

This tag allows you to pull in images from an RSS feed.

A link to any attached file (like a podcast) that displays an icon, file name, and file size

The URL for any attached file (like a podcast)

A link to the external "source" of this item, if one is available. Displays a text URL, without a hyperlink. 
To link this URL in your campaign, insert a link in your campaign content in the text editor, and enter this merge tag in the URL field.

The title of your source URL

Adds a Facebook Like button for the particular RSS item

Adds a Tweet button for the particular RSS item

Adds a Tumblr button for a particular feed item.

Adds a Google+ "+1" button for a particular feed item.

Adds a "Read Later" button for a particular feed item and links to Instapaper to save the URL for the feed item.

Was this article helpful?
What can we do to improve your experience with articles like this?

Technical Support