I want a web page (with the url page3) to be displayed differently depending on whether a user on my website is redirected to it from the pages with urls page1 or page2.

How can I access the full url (not just the query parametres in it) from which the user was redirected in the get method in the view associated with the url page3 ?

有帮助吗?

解决方案

After reading the docs more thoroughly (thanks for the tip Brandon!), I found request.META['HTTP_REFERER'] did the trick.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top