I've just come up against the same problem. I ended up coding a custom
filter as a workaround.
#Custom Filter
@register.filter
def bartest(value, arg):
if (value == int(arg)):
return "trueval"
else:
return "falseval"
>>> snip <<<
template example:
{{ foo.id|bartes
On 3/25/06, bradford <[EMAIL PROTECTED]> wrote:
>
> when i try the following:
>
> {% ifequal bar foo.id|stringformat:"d" %}
>
> I get an error saying that:
> VariableDoesNotExist at /foobars/
> Failed lookup for key [id|stringformat:"d"] in foo
>
> it's as if it strips anything that's before the '
when i try the following:
{% ifequal bar foo.id|stringformat:"d" %}
I get an error saying that:
VariableDoesNotExist at /foobars/
Failed lookup for key [id|stringformat:"d"] in foo
it's as if it strips anything that's before the '.'
please correct me if this is not a bug.
--~--~-~--~