最佳答案
我使用 request.path返回 Django 中的当前 URL,它返回的是 /get/category。
我需要它作为 get/category(没有前导和尾随斜杠)。
我怎么能这么做?