You can use the URL resolver directly in a template, there’s no need to write your own filter. E.g.
{% url 'admin:index' %}
{% url 'admin:polls_choice_add' %}
{% url 'admin:polls_choice_change' choice.id %}
{% url 'admin:polls_choice_changelist' %}
Ref: Documentation
More Related Contents:
- What is a NoReverseMatch error, and how do I fix it?
- Django Admin Show Image from Imagefield
- Django admin: how to sort by one of the custom list_display fields that has no database field
- Django – after login, redirect user to his custom page –> mysite.com/username
- Issue with ManyToMany Relationships not updating immediately after save
- Override default queryset in Django admin
- Django : How can I see a list of urlpatterns?
- Overriding admin css in django
- How to handle request.GET with multiple variables for the same parameter in Django
- Django: How to get current user in admin forms?
- Django “xxxxxx Object” display customization in admin action sidebar
- Django: accessing the model instance from within ModelAdmin?
- How to limit queryset/the records to view in Django admin site?
- Access kwargs from a URL in a Django template
- Using Django auth UserAdmin for a custom user model
- Django admin: How to display a field that is marked as editable=False’ in the model?
- Django admin, hide a model
- Redirect on admin Save
- How do I add a custom column with a hyperlink in the django admin interface?
- How to get URL of current page, including parameters, in a template?
- UnicodeEncodeError: ‘ascii’ codec can’t encode character
- Django Admin – Overriding the widget of a custom form field
- Limit number of model instances to be created – django
- How to add a sortable count column to the Django admin of a model with a many-to-one relation?
- Password field in Django model
- Django templates folders
- Extending Django Admin Templates – altering change list
- Django: access the parent instance from the Inline model admin
- How to have 2 different admin sites in a Django project?
- django: how to access current request user in ModelForm?