PATH:
home
/
letacommog
/
laindinois
/
OLD
/
wp-content
/
plugins
/
responsive-menu
/
vendor
/
twig
/
twig
/
doc
/
filters
``length`` ========== .. versionadded:: 1.33 Support for the ``__toString()`` magic method has been added in Twig 1.33. The ``length`` filter returns the number of items of a sequence or mapping, or the length of a string. For objects that implement the ``Countable`` interface, ``length`` will use the return value of the ``count()`` method. For objects that implement the ``__toString()`` magic method (and not ``Countable``), it will return the length of the string provided by that method. .. code-block:: jinja {% if users|length > 10 %} ... {% endif %}
[+]
..
[-] keys.rst
[edit]
[-] striptags.rst
[edit]
[-] trim.rst
[edit]
[-] spaceless.rst
[edit]
[-] join.rst
[edit]
[-] date.rst
[edit]
[-] index.rst
[edit]
[-] capitalize.rst
[edit]
[-] escape.rst
[edit]
[-] round.rst
[edit]
[-] nl2br.rst
[edit]
[-] raw.rst
[edit]
[-] slice.rst
[edit]
[-] number_format.rst
[edit]
[-] title.rst
[edit]
[-] first.rst
[edit]
[-] format.rst
[edit]
[-] batch.rst
[edit]
[-] sort.rst
[edit]
[-] split.rst
[edit]
[-] filter.rst
[edit]
[-] merge.rst
[edit]
[-] length.rst
[edit]
[-] map.rst
[edit]
[-] upper.rst
[edit]
[-] convert_encoding.rst
[edit]
[-] lower.rst
[edit]
[-] json_encode.rst
[edit]
[-] reverse.rst
[edit]
[-] reduce.rst
[edit]
[-] date_modify.rst
[edit]
[-] last.rst
[edit]
[-] url_encode.rst
[edit]
[-] replace.rst
[edit]
[-] abs.rst
[edit]
[-] default.rst
[edit]