Is there a way to get the current page URL and all its parameters in a Django template?
For example, a templatetag that would print a full URL like /foo/bar?p
/foo/bar?p
In a file context_processors.py (or the like):
def myurl( request ): return { 'myurlx': request.get_full_path() }
In settings.py:
TEMPLATE_CONTEXT_PROCESSORS = ( ... wherever_it_is.context_processors.myurl, ...
In your template.html:
myurl={{myurlx}}