diff options
author | luxagraf@c63593aa-01b0-44d9-8516-4b9c7e931d7f <luxagraf@c63593aa-01b0-44d9-8516-4b9c7e931d7f> | 2010-09-20 15:33:37 +0000 |
---|---|---|
committer | luxagraf@c63593aa-01b0-44d9-8516-4b9c7e931d7f <luxagraf@c63593aa-01b0-44d9-8516-4b9c7e931d7f> | 2010-09-20 15:33:37 +0000 |
commit | bb81806bb58326f0dadfddc38705f0760c7c8d8f (patch) | |
tree | 177bef5ce2ffec926ff3067bd959b10db77261c7 /lib | |
parent | ad23af9549c4bc23ab345966d977e1f5d69ac03d (diff) |
improved html structure and tweaked stylesheet accordingly
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pagination/templates/pagination/pagination.html | 40 |
1 files changed, 10 insertions, 30 deletions
diff --git a/lib/pagination/templates/pagination/pagination.html b/lib/pagination/templates/pagination/pagination.html index 2ecffb4..1afb3d7 100644 --- a/lib/pagination/templates/pagination/pagination.html +++ b/lib/pagination/templates/pagination/pagination.html @@ -1,30 +1,10 @@ -{% load pagination_tags %} -{% if is_paginated %} -<div class="pagination"> - {% if page_obj.has_previous %} - <a href="{% if use_page_path %}{% page_path prev_page %}{% else %}?page={{ page_obj.previous_page_number }}{{ getvars }}{% endif %}" class="prev">‹‹ previous</a> - {% else %} - <span class="disabled prev"></span> - {% endif %} - {% for page in pages %} - {% if page %} - {% ifequal page page_obj.number %} - <span class="current page">{{ page }}</span> - {% else %} - {% if use_page_path %} - <a href="{% page_path page %}" class="page">{{ page }}</a> - {% else %} - <a href="?page={{ page }}{{ getvars }}" class="page">{{ page }}</a> - {% endif %} - {% endifequal %} - {% else %} - ... - {% endif %} - {% endfor %} - {% if page_obj.has_next %} - <a href="{% if use_page_path %}{% page_path next_page %}{% else %}?page={{ page_obj.next_page_number }}{{ getvars }}{% endif %}" class="next">next ››</a> - {% else %} - <span class="disabled next">next ››</span> - {% endif %} -</div> -{% endif %} +{% load pagination_tags %}{% if is_paginated %} + <ul class="pages">{% if page_obj.has_previous %} + <li><a href="{% page_path prev_page %}" class="prev">‹‹ previous</a></li>{% else %} + <li class="disabled prev"></li>{% endif %}{% for page in pages %}{% if page %}{% if page == page_obj.number %} + <li class="current page">{{ page }}</li>{% else %} + <li><a href="{% page_path page %}" class="page">{{ page }}</a></li>{% endif %}{% else %} + <li>...</li>{% endif %}{% endfor %}{% if page_obj.has_next %} + <li><a href="{% if use_page_path %}{% page_path next_page %}{% else %}?page={{ page_obj.next_page_number }}{{ getvars }}{% endif %}" class="next">next ››</a></li>{% else %} + <li class="disabled next">next ››</li>{% endif %} + </ul>{% endif %}
\ No newline at end of file |