# In the views
def my_view(request):
...
queries_without_page = request.GET.copy()
if queries_without_page.has_key('page'):
del queries_without_page['page']
...
context['queries'] = queries_without_page
...
# In the templates
{% for p in page_range %}
{{p}}
{% empty %}
1
{% endfor %}