djangosnippets.org: Latest snippets tagged with 'ellipsis'https://djangosnippets.org/tags/ellipsis/2015-10-23T15:23:32.571887-05:00Ellipsis paginator decorator with first and last two items
2015-10-23T15:23:32.571887-05:00karolyihttps://djangosnippets.org/snippets/10535/<p>Use this template tag to get a paginator showing the first and last two pages w/ adjacent pages using ellipsis.</p>
<p>The <code>page</code> parameter is a page of a <code>Paginator</code> (typically the first but you can use whichever you want).</p>
<p>In case of 50 pages, while being on the 40th, it'll …</p>
Freely redistributable