Updated template docs to reflect [587]
git-svn-id: http://code.djangoproject.com/svn/django/trunk@588 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
def5d10ffc
commit
2577581808
|
@ -445,22 +445,20 @@ Built-in tag reference
|
||||||
|
|
||||||
Example::
|
Example::
|
||||||
|
|
||||||
{% ifequal user.id_ comment.user_id %}
|
{% ifequal user.id comment.user_id %}
|
||||||
...
|
...
|
||||||
{% endifequal %}
|
{% endifequal %}
|
||||||
|
|
||||||
As in the {% if %} tag, an {% else %} clause is optional.
|
As in the ``{% if %}`` tag, an ``{% else %}`` clause is optional.
|
||||||
|
|
||||||
|
The arguments can be hard-coded strings, so the following is valid::
|
||||||
|
|
||||||
|
{% ifequal user.username "adrian" %}
|
||||||
|
...
|
||||||
|
{% endifequal %}
|
||||||
|
|
||||||
``ifnotequal``
|
``ifnotequal``
|
||||||
Output the contents of the block if the two arguments do not equal each other.
|
Just like ``ifequal``, except it tests that the two arguments are not equal.
|
||||||
|
|
||||||
Example::
|
|
||||||
|
|
||||||
{% ifnotequal user.id_ comment.user_id %}
|
|
||||||
...
|
|
||||||
{% endifnotequal %}
|
|
||||||
|
|
||||||
As in the {% if %} tag, an {% else %} clause is optional.
|
|
||||||
|
|
||||||
``load``
|
``load``
|
||||||
Load a custom template tag set.
|
Load a custom template tag set.
|
||||||
|
@ -523,14 +521,14 @@ Built-in tag reference
|
||||||
``ssi``
|
``ssi``
|
||||||
Output the contents of a given file into the page.
|
Output the contents of a given file into the page.
|
||||||
|
|
||||||
Like a simple "include" tag, the ``ssi`` tag includes the contents
|
Like a simple "include" tag, ``{% ssi %}`` includes the contents of another
|
||||||
of another file -- which must be specified using an absolute page --
|
file -- which must be specified using an absolute path -- in the current
|
||||||
in the current page::
|
page::
|
||||||
|
|
||||||
{% ssi /home/html/ljworld.com/includes/right_generic.html %}
|
{% ssi /home/html/ljworld.com/includes/right_generic.html %}
|
||||||
|
|
||||||
If the optional "parsed" parameter is given, the contents of the included
|
If the optional "parsed" parameter is given, the contents of the included
|
||||||
file are evaluated as template code, with the current context::
|
file are evaluated as template code, within the current context::
|
||||||
|
|
||||||
{% ssi /home/html/ljworld.com/includes/right_generic.html parsed %}
|
{% ssi /home/html/ljworld.com/includes/right_generic.html parsed %}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue