1
我想要在Django中獲取所需網址的完整路徑。我使用這種網址格式: ('^',myawesomeview), 它適用於domain.com/hello,domain.com/hello/sdfsdfsd,甚至可以用於domain.com/hello.php/sd""^some !bullshit.index.aspx(雖然「^」替換爲「%5E」)Django的url模式 - 如何獲得網頁的絕對url?
但是,當我嘗試在請求中使用#(例如http://127.0.0.1:8000/solid#url)時,它只返回「/ sold」。有沒有辦法在沒有任何更改或替換的情況下獲得完整路徑?
順便說一句,I'getting網址與返回HttpResponse(request.path) 在此先感謝。