forloop.counter

52 views
Skip to first unread message

luca72.b...@gmail.com

unread,
Oct 15, 2020, 10:32:31 AM10/15/20
to Django users
i have this :
 {% if forloop.counter < {{ variable }} %}
i have this error:

Could not parse the remainder: '{{' from '{{' 

how i can solve it?
Thanks 

Larry Martell

unread,
Oct 15, 2020, 10:39:45 AM10/15/20
to django...@googlegroups.com
You don't need {{ }} inside of a {% %}

luca72.b...@gmail.com

unread,
Oct 15, 2020, 10:53:53 AM10/15/20
to Django users
thanks i forgot it

nirali sanghvi

unread,
Oct 15, 2020, 11:01:10 AM10/15/20
to django...@googlegroups.com
Ig this is bcoz u are using jinga format in a jinga format.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/58585ced-68c2-4b46-862f-36f919d13555n%40googlegroups.com.

GBELE CEDRIC EMMANUEL

unread,
Oct 15, 2020, 11:11:42 AM10/15/20
to django...@googlegroups.com
{% if forloop.counter < variable  %}   

Reply all
Reply to author
Forward
0 new messages