Articles on: Expression language

Number Functions

With Number functions, the Text component must have the Format set to Number.

Format number

Format a number with grouped thousands and optionally decimal digits.
{% number_format([float number], [decimal_places], [decimal_separator], [thousands_separator]) %}


Round

Round the float number based on the precision from the second parameter.
{% round([float number], [integer precision]) %}


Ceil

Rounds to the nearest integer up. E.g. 2.1 => 3.
{% ceil ([float number]) %}


Floor

Rounds to the nearest integer down. E.g. 2.8 => 2.
{% floor ([float number]) %}


Pow

Number in power of.
{% pow([float base value], [integer|float power of]) %}


Sqrt

Square root of a number.
{% sqrt ([float base value])%}

Updated on: 18/12/2022

Was this article helpful?

Share your feedback

Cancel

Thank you!