Tutorials » Custom RSS Feed

Goals

Create an RSS feed with the following features beyond &format=`rss`:

  • Hardcoded author name
  • The entire contents of each article shows instead of a summary

Steps

  1. Create a new chunk call "ditto_rss_tpl" with the contents: <item> <title>[+rss_pagetitle+]</title> <link>[(site_url)][~[+id+]~]</link> <description><![CDATA[ [+content+] ]]></description> <pubDate>[+rss_date+]</pubDate> <guid isPermaLink="false">[(site_url)][~[+id+]~]</guid> <dc:creator>[(site_name)]</dc:creator> [+tagLinks+] </item>

    In this chunk, [(site_name)] replaces the current documents author and [+content+] returns the entire document instead of just its summary

  2. Add [!Ditto? &format=`rss` &tpl=`ditto_rss_tpl`!] to a new document titled [(site_name)] Feed
  3. Make sure the document template is blank and the content-type text/xml