Answer the question
In order to leave comments, you need to log in
How to parse a request like this in Django 3: https://some domain/category.php?cat={number}?
There is a site written in php and url address like https://some domain/category.php?cat={number}. I need to specify the path in django 3 in urls.py so that without breaking the old url category.php?cat={number} get the value cat.
Answer the question
In order to leave comments, you need to log in
urls.py
views.py
path('category.php', your_view)
def your_view(request):
cat = request.GET['cat']
...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question