(Apr-21-2023, 11:28 AM)snippsat Wrote: Can eg use urlparse.
[python]>>> from urllib.parse import urlparse
>>>
.............
How do I embed this code in tempates?
I have a menu with links on my site. I create links using get_absolute_url
When I follow the link, I call the view with the desired template. In this template, I need to find out: where I came from (i.e. slug!) (by slug I will find the menu item, menu parent and assign the necessary classes in the desired place of the menu)
Probably i can just pass to view everything that I need to disassemble in the template???
But I had not yet studied this moment. If this is more correct, then I will go this way.