aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/entries.xml.twig
blob: d70aa5dc9c99e58fa043d47183ae5e936e0a164f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:media="http://search.yahoo.com/mrss/">
    <channel>
        <title>wallabag - {{ type }} feed</title>
        <link>{{ url_html }}</link>
        <link rel="self" href="{{ app.request.uri }}"/>
        {% if entries.hasPreviousPage -%}
            <link rel="previous" href="{{ url }}?page={{ entries.previousPage }}"/>
        {% endif -%}
        {% if entries.hasNextPage -%}
            <link rel="next" href="{{ url }}?page={{ entries.nextPage }}"/>
        {% endif -%}
        <link rel="last" href="{{ url }}?page={{ entries.nbPages }}"/>
        <pubDate>{{ "now"|date('D, d M Y H:i:s') }}</pubDate>
        <generator>wallabag</generator>
        <description>wallabag {{ type }} elements</description>

        {% for entry in entries %}

            <item>
                <title><![CDATA[{{ entry.title|e }}]]></title>
                <source url="{{ url('view', { 'id': entry.id }) }}">wallabag</source>
                <link>{{ entry.url }}</link>
                <guid>{{ entry.url }}</guid>
                <pubDate>{{ entry.createdAt|date('D, d M Y H:i:s') }}</pubDate>
                <description>
                    <![CDATA[{%- if entry.readingTime > 0 -%}{{ 'entry.list.reading_time_minutes'|trans({'%readingTime%': entry.readingTime}) }}{%- else -%}{{ 'entry.list.reading_time_less_one_minute'|trans|raw }}{%- endif %}{{ entry.content|raw -}}]]>
                </description>
            </item>

        {% endfor %}

    </channel>
</rss>