Bingo! Thanks much. ./s
On May 26, 6:57 pm, Rendy Anthony <[email protected]> wrote: > You also need to return the result of bar() from foo. Example: > > def bar(request): > print "In bar" > return HttpResponseRedirect('"http://example.com") > > def foo(request): > return bar() > > Regards, > Rendy Anthonyhttp://solyaris.wordpress.com > > > > On Thu, May 27, 2010 at 9:50 AM, shacker <[email protected]> wrote: > > I'm trying to figure out why HttpResponseRedirect doesn't work when > > called from within another function. For example, this works, of > > course: > > > def foo(request): > > return HttpResponseRedirect('"http://example.com") > > > But this does not: > > > def bar(request): > > print "In bar" > > return HttpResponseRedirect('"http://example.com") > > > def foo(request): > > bar() > > > In this second case, django will print "In bar" but the redirect does > > not occur - it fails silently. Feel like I'm not understanding > > something fundamental here. > > > Clues? Thanks. > > > -- > > You received this message because you are subscribed to the Google Groups > > "Django users" group. > > To post to this group, send email to [email protected]. > > To unsubscribe from this group, send email to > > [email protected]<django-users%2bunsubscr...@google > > groups.com> > > . > > For more options, visit this group at > >http://groups.google.com/group/django-users?hl=en. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected]. 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.

