from django import template register = template.Library() @register.filter def replace(value, cherche, remplacement): retur
Instead of a filter, register your tag as a simple tag. Those can take multiple arguments. The syntax for invoking it will be a little bit different, but that's just syntactic sugar changing.