The filter |set{name} affects the current value of the variable name. It is sometimes more convenient alternative, to the tag #SET{name,value}.


[(#GET{lenght}) characters]

is the equivalent to

[(#GET{lenght}) characters]

The second argument of the |set{} filter, if not null, indicates to "continue", that is, pass the value in the sequence of filters, or display it if placed at the end of the chain:

[(#TEXTE*|set{plain,1}|propre|set{process,1}|mb_strlen|set{lenght,1})] stores the plain text in the variable plain, the text processed in process, the number of characters in lenght, and eventually displays the value lenght.
See also |setenv

The |set filter was introduced in SPIP 2.1 and SPIP 3 on 3 June 2014.

Author jack Published : Updated : 09/02/16

Translations : English, français, Nederlands