def METHOD_NAME(request):
    query = request.GET.copy()
    query.setlist('page', [])
    query = query.urlencode()
    if query:
        return {'page_prefix': '%s?%s&page=' % (request.path, query),
                'first_page_href': '%s?%s' % (request.path, query)}
    else:
        return {'page_prefix': '%s?page=' % request.path,
                'first_page_href': request.path}