Experience with Craft's native rss/atom support? I'm trying to use the native support for rss and atom as described in the documentation, but it misses some info.


https://craftcms.com/docs/templating/atom-feed
https://craftcms.com/docs/templating/rss-feed


Did anyone got this to work? I'm not even sure how to name my template or what the url is going to be.

I tried the following template names:
template.twig.atom
template.atom.twig
template.atom

I tried requests with atom in the header and .atom postfix. Both without any success.
Yeah, so I have a rss.twig file in the root of my template directory.

{% header "Content-Type: application/rss+xml" %}
&lt;?xml version="1.0" encoding="UTF-8" ?&gt;
&lt;rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"&gt;

{% set rss = craft.entries.section('article').limit(10).type('article') %}

&lt;channel&gt;
  &lt;title&gt;My Site Name&lt;/title&gt;
  &lt;link&gt;{{ siteUrl }}&lt;/link&gt;
  &lt;description&gt;My site description&lt;/description&gt;
  &lt;language&gt;en-au&lt;/language&gt;
  &lt;atom:link href="{{ url() }}" rel="self" type="application/rss+xml" /&gt;

  {% for item in rss %}
  &lt;item&gt;
    &lt;title&gt;&lt;![CDATA[{{ item.title|raw }}]]&gt;&lt;/title&gt;
    &lt;link&gt;{{ item.url() }}&lt;/link&gt;
    &lt;description&gt;&lt;![CDATA[
    {% for block in item.body %}

  {% if block.type == "text" %}

    {{ block.text }}

  {% elseif block.type == "footnote" %}

    {% include 'blocks/_footnote' %}

  {% elseif block.type == "pullQuote" %}

    {% include 'blocks/_pullquote' %}

  {% elseif block.type == "heading" %}

    {% include 'blocks/_heading' %}

  {% elseif block.type == "image" %}

    {% include 'blocks/_image' %}

  {% elseif block.type == "audio" %}

    {% include 'blocks/_audio' %}

  {% elseif block.type == "video" %}

    {% include 'blocks/_video' %}

  {% endif %}

{% endfor %}]]&gt;&lt;/description&gt;
    &lt;pubDate&gt;{{ item.postDate.rfc2822() }}&lt;/pubDate&gt;
    &lt;guid&gt;{{ item.url() }}&lt;/guid&gt;
  &lt;/item&gt;
  {% endfor %}
&lt;/channel&gt;

&lt;/rss&gt;


If I access, http://myurl.com/rss - I get my lovely feed.