Skip to content

Commit

Permalink
Removed outdated condition section on Django
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Greenfeld committed Aug 6, 2015
1 parent 57c288c commit ff4ffde
Showing 1 changed file with 0 additions and 31 deletions.
31 changes: 0 additions & 31 deletions docs/switching.rst
Original file line number Diff line number Diff line change
Expand Up @@ -116,37 +116,6 @@ Python syntax. Thus this Django code::
This allows you to pass variables to the method, which is not possible in
Django. This syntax is also used for macros.

Conditions
~~~~~~~~~~

In Django you can use the following constructs to check for equality::

{% ifequal foo "bar" %}
...
{% else %}
...
{% endifequal %}

In Jinja2 you can use the normal if statement in combination with operators::

{% if foo == 'bar' %}
...
{% else %}
...
{% endif %}

You can also have multiple elif branches in your template::

{% if something %}
...
{% elif otherthing %}
...
{% elif foothing %}
...
{% else %}
...
{% endif %}

Filter Arguments
~~~~~~~~~~~~~~~~

Expand Down

0 comments on commit ff4ffde

Please sign in to comment.