1
0
mirror of https://github.com/r4sas/py-i2phosts synced 2025-01-08 22:07:55 +00:00
py-i2phosts/pyi2phosts/templates/browse.html
Hidden Z 84836a5079 Simplify pagination in browse.html
Our old pagination is incompatible with new class-based generic views,
so switch to internal django pagination for some time.
2011-12-23 18:57:42 +00:00

36 lines
1.1 KiB
HTML

{% extends "base.html" %}
{% load i18n %}
{% block header %}
<h3>{% trans "All active hosts in I2P" %}
<a href={% url browse-rss %}><img src="/static/rss-grey-18.png" border="0" width="18" height="18" alt="rss"></a></h3>
{% endblock %}
{% block content %}
<table>
<tr><td>{% trans "Host" %}</td><td>{% trans "Last seen" %}</td><td>{% trans "Date added" %}</td><td>{% trans "Description" %}</td></tr>
{% for host in host_list %}
<tr><td><a href="http://{{ host.name }}/?i2paddresshelper={{host.b64hash}}">{{ host.name }}</a></td><td>{{ host.last_seen }}</td>
<td>{{ host.date_added }}</td><td>{{ host.description }}</td></tr>
{% endfor %}
</table>
{% if is_paginated %}
<div class="pager">
{% if page_obj.has_previous %}
<span class="page">
<a href="?page={{ page_obj.previous_page_number }}">&lt; Prev</a>
</span>
{% endif %}
<span class="current">Page {{ page_obj.number }} of {{ paginator.num_pages }}</span>
{% if page_obj.has_next %}
<span class="page"><a href="?page={{ page_obj.next_page_number }}">Next &gt;</a></span>
{% endif %}
{{ paginator.count }} {% trans "hosts total" %}
{% endif %}
{% endblock %}