On Sat, 2007-04-21 at 01:47 -0700, Michael wrote: > I'm not sure if this is obvious, but the documentation at: > > http://www.djangoproject.com/documentation/url_dispatch/#naming-url-patterns > > 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 > django_src/django/template/defaulttags.py): > > 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 > patterns...
We haven't documented reverse() anywhere, as far as I know. So worth filing a ticket. Thanks, Malcolm --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---