How do you get the URI from request object in Django?

和自甴很熟 提交于 2020-08-27 06:43:40

问题


How do you get the URI from request object in Django?

Is there request.uri?


回答1:


request.META['REQUEST_URI']

or

request.get_full_path()

You tend to generate a flood of trivial questions, answers to which you could easily find in documentation/Google...



来源:https://stackoverflow.com/questions/2673069/how-do-you-get-the-uri-from-request-object-in-django

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!