Reputation: 140
I am using django-el-pagination package and trying to implement digg-style pagination on my home template. I am displaying it with..
{% get_pages %}
{{ pages.get_rendered }}
and it is showing like this <1234567> which is fine but
If you have any other way to achieve this. Please suggest..
please tell how can I customize it.
Upvotes: 1
Views: 281
Reputation: 1785
You can change it to make it looks something like this or like whatever you want:
Here is an example:
{% get_pages %}
<div class="pagination">
{% for page in pages %}
<li class="page-item"><a href="{{ page.url }}" class="page-link">{{ page.number }}</a></li>
{% endfor %}
</div>
You can check the documentation here: https://django-el-pagination.readthedocs.io/en/latest/templatetags_reference.html#get-pages to check all the available options for get_pages
Upvotes: 0