SHARE
TWEET

Untitled

a guest Jun 25th, 2019 52 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. def raison(request, individu_id):
  2.     # code here
  3.      
  4. HttpResponseRedirect('%i/raison/' % individu_id)
  5.      
  6. from django.core.urlresolvers import reverse
  7.  
  8.  
  9. def index(request):
  10.    # code here
  11.    if ...:
  12.        next = reverse("raison", kwargs={"individu_id": individu_id})
  13.        return HttpResponseRedirect(next)
  14.      
  15. from django.shortcuts import redirect
  16.  
  17.  
  18. def index(request):
  19.    # code here
  20.    if ...:
  21.        return redirect("raison", individu_id=individu_id)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top