The Django docs (and a lot else) recommend redirecting after successfully processing a post request (if it changes data). i.e. post, the save stuff to the database, then redirect.
Current browsers seem to allow this. I have tried Chromium 28 and 24 on Linux, I user return redirect(...) after the post, and I can still use the back button.
Is it my configuration, or is it usual? What is the best practice if this is broken?
In some cases I think tracking where the user is (in the session, or using the state of a particular object such as an order model), and redirecting any request for an earlier page in a sequence may be the way to go. Or is this a solved problem that I am too far behind the curve to know about?
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/71edbe7c-5e3b-48e9-9469-434fdc153473%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
No comments:
Post a Comment