Answer the question
In order to leave comments, you need to log in
Getting array from url, python?
Hello! From the link (example.com/forum/page/1) you need to get an array(["forum", "page", "1"]), but the problem is that this needs to be done when entering the page. Website in pure python.
PS Something like view is necessary. Or how is he...
Answer the question
In order to leave comments, you need to log in
If you write your bike (which in itself is a good undertaking), then immediately do it right. You are trying to implement routing. See how it is implemented in ready-made solutions:
Django
Flask
You also need to decide whether your application will work on WSGI or will be a web server itself. Then the answer to your question will become clear.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question