Variable Modifiers
Variable modifiers allow you to quickly alter the value of a tag on the fly within your templates. Below is a complete list of all of the variable modifiers currently available within Statamic, including a bit about how each one works.
play Watch our screencasts:
String Modifiers and Loop Modifiers
- % (Modulus)
- * (Multiply)
- + (Add)
- - (Subtract)
- / (Divide)
- ^ (Exponent)
- abs
- acos
- ago
- ampersand_list
- asin
- atan
- backspace
- bindec
- ceil
- censor
- contains
- cos
- decbin
- dechex
- decoct
- deg2rad
- deslugify
- distance_in_km_from
- distance_in_mi_from
- double
- dump
- empty
- ends_with
- entities
- floor
- format
- format_number
- hexdec
- img
- in_future
- in_past
- is_today
- is_tomorrow
- is_weekday
- is_weekend
- length
- link
- list
- log
- log10
- lower
- markdown
- nl2br
- not_empty
- numeric
- obfuscate
- octdec
- option_list
- ordered_list
- ordinal
- rad2deg
- relative
- remove_left
- remove_right
- repeat
- replace
- required_list
- reverse
- rot13
- round
- sanitize
- scramble
- sentence_list
- sin
- since
- slugify
- smartypants
- spaced_list
- specialchars
- sqrt
- starts_with
- strip_spaces
- striptags
- tan
- textile
- title
- trim
- triple
- truncate
- ucfirst
- unordered_list
- until
- upper
- urldecode
- urlencode
- widont
- word_count