<h3>Förflutna events</h3>
{% capture now -%}
{{ site.time | date: '%s' }}
{%- endcapture %}
{% assign events = site.events | reverse %}
{% for event in events | limit: 7 %}

{% capture endtime -%}
{{ event.event_data.end_datetime | date: '%s' }}
{%- endcapture %}

{% if now >= endtime %}
<div>
  <p>{{ event.event_data.start_datetime | date: '%Y-%m-%d' }}<br />
    <a href="{{ event.url }}"><strong>{{ event.title }}</strong></a>
  </p>

  <br />
</div>
{% endif %}
{% endfor %}
<a href="/events/" class="cta" alt="Events">Mer Events</a>
<br /><br />