Re: Setting variable in custom template

2017-04-04 Thread Mahendra Gaur
Why do you want to set it in custom template. It would be better if you put this variable in context dictionary while rendering and then use it in the template on the basis of condition. Thanks and regards, Mahendra On 4 Apr 2017 7:44 p.m., "valerio orfano" wrote: > Hi there > > is there any c

RE: Setting variable in custom template

2017-04-04 Thread Matthew Pava
You can use the {% with %} tag. https://docs.djangoproject.com/en/1.10/ref/templates/builtins/#with From: django-users@googlegroups.com [mailto:django-users@googlegroups.com] On Behalf Of valerio orfano Sent: Tuesday, April 4, 2017 9:15 AM To: Django users Subject: Setting variable in custom tem