0
有沒有辦法瞭解django視圖中的上一個url?我的意思是如何知道從哪個網址(我網站中的網頁)用戶來到這個網址?我發現在模板中這樣做,但我想知道它在視圖中。如何理解以前的網址
def func(request):
if request.is_ajax():
//if the last url was the url of this page, do s.th
//else do s.th else
謝謝