I know you can refer to a urlname in a template so that you don't need to hardcode your url links in your templates whenever you want to change them.
For example in a template, I use:
<a href="{% url 'urlname' parameter %}">The link</a>
My problem is, if I want to pass a more complex parameter to be used in the url regex. In my case, I want to pass a concatenation of two strings separated by an "_". Those strings come from Python objects and I don't get how to do that. Let's say for example, those strings are the firstname and lastname of a user.
I tried:
<a href="{% url 'urlname' "user.firstname_user.lastname" %}">The link</a>
And others tricks but none worked.
Can someone help?