Setting up RSS Feeds

Answered

Comments

8 comments

  • Official comment
    James Vidler

    Ok, that makes sense. Looks like there's a bug where the staging content files don't get updated when you change the reference name and/or update RSS settings. You'll want to test this in Live Mode as well to make sure you don't have the same problem. If you do, you can try changing the "Default Sort" order - which will sync the list again.

    In regards to mapping the fields, I've updated the documentation on Syndicating Content with RSS which provides an example of how to map the fields:

    Example:

    Generate an RSS feed using fields from the content definition

    /ecmsrss.aspx/BlogPosts.xml?Lang=en-us&descriptionfield=BlogContent&
    Link=https://{site}/blog/blog-details&Query=contentid&TitleField=Title

    Which results in an output such as:

    <rss version="2.0">
        <channel>
            <title>Blog Posts</title>
            <description>Blog Posts</description>
            <link>https://{site}/blog/blog-details</link>
            <language>en-us</language>
            <generator>Agility CMS</generator>
            <lastBuildDate>Tue, 18 Dec 2018 17:33:52 +0000</lastBuildDate>
            <item>
                <title>
                    <![CDATA[ My Blog Post Title ]]>
                </title>
                <link>https://{site}/blog/blog-details?contentid=3087</link>
                <description>
                    <![CDATA[
                        <p>This is a description for a blog post</p> 
                    ]]>
                </description>
                <pubDate>Mon, 17 Dec 2018 01:27:39 +0000</pubDate>
            </item>
        </channel>
    </rss>
  • James Vidler

    Hi Jeff,

    That should do the trick. To help troubleshoot though, have you tried running this locally? If it works locally, but not on the deployed web server then it could indicate a sync issue.

  • Jeff Yang

    Hey James,

    That was the error message when I tried locally.

  • James Vidler

    Hi Jeff,

    I was able to enable it on another list /ecmsrss.aspx/FeaturedBlogs.xml so there's something specific to the BlogPosts list that isn't working as expected. Just trying to narrow things down here, but is there a chance that there used to be an existing list with the same reference name?

     

  • Jeff Yang

    Yes. There used to be a list with the same reference name which I had to change.  Forgot which one exactly.. It might have been corporate blogs as it is using the same content def.

  • James Vidler

    I also found that /ecmsrss.aspx/BlogPosts.xml?Lang=es actually works, but not /ecmsrss.aspx/BlogPosts.xml?Lang=en.

  • James Vidler

    Could you try clearing your local content files and see if that resolve the issue? You can delete everything in the AgilityContent directory as it is defined in the web.config.

  • Jeff Yang

    Hey James,

    That did the trick.  I can see the RSS feed now.  There is a secondary issue though. 

    In the RSS feed, all the <description> content are empty.  Does the body of each content item need to be named description?  Also, that content is an RTA. would that be fine?  Thanks

Please sign in to leave a comment.