Add "reverse" to url_dispatch documentation for named url patterns
|Reported by:||Owned by:||Jacob|
|Has patch:||yes||Needs documentation:||yes|
|Needs tests:||no||Patch needs improvement:||no|
Just a small addition to the documentation for accessing named URL patterns at:
See email exchange between myself and Malcolm below...
On Sat, 2007-04-21 at 01:47 -0700, Michael wrote:
I'm not sure if this is obvious, but the documentation at:
doesn't mention how you can use your named URL patters to redirect
from one view to another. It only shows how you can get the url for a
view from within a template.
Anyways, turns out to be pretty simple (found it in the source
from django.core.urlresolvers import reverse
return HttpResponseRedirect( reverse( 'your-url-name' ) )
Have I missed something and this was documented else where? Otherwise
I'll raise a ticket to update the above documentation for named url
We haven't documented reverse() anywhere, as far as I know. So worth
filing a ticket.
Change History (6)
comment:1 Changed 10 years ago by
|Keywords:||docs url_dispatch added|
|Summary:||Addition to url_dispatch documentation for named url patterns → Add "reverse" to url_dispatch documentation for named url patterns|
|Triage Stage:||Unreviewed → Accepted|