[Answered ]-NoReverseMatch for Django and DjangoCMS App

1👍

You need to pass the .slug of the tag as parameter of the URL, so:

<a href="{% url 'article-list-by-tag' tag=tag.slug %}" class="badge badge-info" >{{ tag }}</a>

If you import it with a namespace, you need to prefix the name of the view with that prefix, so 'some_namespace:article-list-by-tag'.

0👍

In case it helps anyone, the following code worked for my use-case:

<a href="{% namespace_url 'article-list-by-tag' tag=tag.slug %}" class="badge badge-info" >{{ tag }}</a>

Where the namespace_url is a template tag provided by DjangoCMS.

Leave a comment