Hello!

Tell me how to make pagination in this format:

http://site.ru/queries/page2/ 

instead:

 http://site.ru/queries/?page=2 

Need to write twice in urls.py?

 url(r'^queries/$', QueryListActive.as_view(), name='query_list'), url(r'^queries/page(?P<page>\d+)/$', QueryListActive.as_view(), name='query_list') 

    1 answer 1

    Yes, you need to write the url twice, but in general it is better not to do that. It is believed (and search engines love it) that one resource (list of objects) should be available at one URL, and filters and page lists are the parameters of this resource.