Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: b049a3296c
Fetching contributors…

Cannot retrieve contributors at this time

41 lines (37 sloc) 2.089 kb
{% extends "base.html" %}
{% load core_tags %}
{% block title %}All snippets{% if months %} last {{ months }} months{% endif %}{% endblock %}
{% block content_header %}All snippets{% if months %} last {{ months }} months{% endif %}{% endblock %}
{% block content %}
<ul class="snippet_filter">
<li{% if not months %} class="active"{% endif %}><a href="{{ request.path }}">Any time</a></li>
<li{% if months == 3 %} class="active"{% endif %}><a href="{{ request.path }}?months=3">3 months</a></li>
<li{% if months == 6 %} class="active"{% endif %}><a href="{{ request.path }}?months=6">6 months</a></li>
<li{% if months == 12 %} class="active"{% endif %}><a href="{{ request.path }}?months=12">1 year</a></li>
</ul>
{% if object_list %}
<ul class="snippet_list">
{% for snippet in object_list %}
<li>
<a href="{{ snippet.get_absolute_url }}">{% if not snippet.title|strip %}Untitled{% else %}{{ snippet.title }}{% endif %}</a> by <a href="/users/{{ snippet.author.username }}/">{{ snippet.author.username }}</a>
<p class="details">{{ snippet.pub_date|timesince }} ago, <span class="rating-{% if snippet.rating_score >= 0 %}positive{% else %}negative{% endif %}">{% if snippet.rating_score >= 0 %}+{% endif %}{{ snippet.rating_score }}</span></p>
</li>
{% endfor %}
</ul>
<p class="pagination">
{% if has_previous %}
<a href="?page={{ previous }}{% if months %}&amp;months={{ months }}{% endif %}">&lt; Previous {{ results_per_page }}</a>
{% endif %}
&nbsp;&nbsp;
{% if has_next %}
<a href="?page={{ next }}{% if months %}&amp;months={{ months }}{% endif %}">Next {{ results_per_page }} &gt;</a>
{% endif %}
</p>
{% else %}
<p class="empty">No snippets posted yet.</p>
{% endif %}
{% endblock %}
{% block sidebar %}
<p>{{ hits }} snippet{{ hits|pluralize }} posted so far.</p>
<p><a rel="alternate" href="/feeds/latest/" type="application/atom+xml"><img src="{{ STATIC_URL }}img/feed-icon-10x10.gif" alt="" /> Feed of latest snippets</a></p>
{% endblock %}
Jump to Line
Something went wrong with that request. Please try again.