aboutsummaryrefslogtreecommitdiff
path: root/templates/web/atom.xml
blob: c03bfe34c4258ba89de31aa72556abd31e44a8b8 (plain)
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
35
36
37
38
39
40
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <generator uri="https://git.sr.ht/~fabrixxm/lesanaweb">Lesana Web</generator>
  <title>{% if q %}Results for '{{ q }}' - {% endif %}{{ settings.name }}</title>
  <author>
    <name>GL-Como</name>
    <uri>https://gl-como.it</uri>
  </author>
  <icon>{{ siteurl }}{{ url_for('static', filename='linkopedia_rgb.svg') }}</icon>
  <link href="{{ siteurl }}" />
  <link href="{{ siteurl }}/atom.xml{% if q %}?q={{ q|urlencode }}{% endif %}" rel="self" />
  <updated>{{ entries.0.data.updated.strftime("%Y-%m-%dT%H:%M:%SZ") }}</updated>
  <id>{{ siteurl }}/atom.xml{% if q %}?q={{ q|urlencode }}{% endif %}</id>

  {% for entry in entries %}
  <entry>
    <title>{{ entry.data.title }}</title>
    <author>
      <name>GL-Como</name>
      <uri>https://gl-como.it</uri>
    </author>
    <link href="{{ siteurl }}{{ url_for('entry', eid=entry.eid) }}"/>
    <id>urn:lesana:{{ entry.eid }}</id>
    <updated>{{ entry.data.updated.strftime("%Y-%m-%dT%H:%M:%SZ") }}</updated>
    <summary>{% if entry.data.description %}{{ entry.data.description }}{% else %}{{ entry.data.url }}{% endif %}</summary>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>{{ entry.data.description }} - {{ entry.data.url }}</p>
        <p>{% for tag in entry.data.tags %}
          <a class="tag" href="{{ siteurl }}{{ url_for('search') }}?q=tags:{{tag|urlencode}}">#{{ tag }}</a>
        {% endfor %}</p>
      </div>
    </content>
    {% for tag in entry.data.tags %}
    <category term="{{tag}}"/>
    {% endfor %}
  </entry>
  {% endfor %}

</feed>