paginated.html 1.14 KB
Newer Older
Jacek Lebioda's avatar
Develop  
Jacek Lebioda committed
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 41 42 43 44 45 46
---
layout: default
---

<article class="body-wrapper margin-wrapper">

    <div id="left-column">
    </div>

    <div>
        <header>
            <h1>
                ELIXIR.LU news
            </h1>
            <hr />
        </header>

        {% for post in paginator.posts %}
        <div class="post">
          <a class="post-title" href="{{ post.url | relative_url }}">{{ post.title }}</a>

          <span class="post-date">Published on: {{ post.date | date: '%B %d, %Y' }}</span>

          <div class="content">
            {{ post.content | truncate: 220 }}
          </div>
        </div>
        {% endfor %}

        <div class="pagination">
          {% if paginator.previous_page %}
            <a href="{{ paginator.previous_page_path | relative_url }}" class="previous">
              Previous
            </a>
          {% endif %}

          <span class="page_number ">
            Page: {{ paginator.page }} of {{ paginator.total_pages }}
          </span>

          {% if paginator.next_page %}
            <a href="{{ paginator.next_page_path | relative_url }}" class="next">Next</a>
          {% endif %}
        </div>
    </div>
</article>