Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,059 of 9,059 pages
About the help in other languages
All help pages

Twig templates: operator reference

This page is for template developers who write .twig templates and need the exact form of one operator. It lists the template operators of the kernel, of the template library and of the extensions of the standard…

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/guides/twig-templates-operator-reference.md

On this page

Twig templates: operator reference

This page is for template developers who write .twig templates and need the exact form of one operator. It lists the template operators of the kernel, of the template library and of the extensions of the standard distribution, with the filter form (with an input) and the function form (without one) a .twig uses, and how the operator takes its input. The rules behind the columns are in Operators and fetch functions.

The tables were written from the operators the template system registers (eZTemplate::factory()->Operators) on a development installation; an extension you add brings its operators the same way, and every one of them is a filter and a function of the same name.

How to read the tables

  • Filter form: x|name(...), the operator with an input, as {$x|name( ... )} in a .tpl.
  • Function form: name(...), the operator without an input, as {name( ... )} in a .tpl.
  • exp_ forms: where Twig has a filter or function of the same name, or the name is a word of Twig's parser (and, or, not, true, false, null), the operator is exp_<name>. exp_<name> works for every operator.
  • Input: input: the operator works on its input (the filter form gives it); param: the input becomes the first parameter, so x|op(y) and op(x, y) are the same call; ignores input: a control operator or one that reads its parameters only.

Kernel (kernel/)

OperatorFilter formFunction formInputClass file
action_iconx|action_iconaction_icon()inputezwordtoimageoperator.php
alphabetx|alphabetalphabet()ignores inputezalphabetoperator.php
audit_labelx|audit_labelaudit_label()inputexpaudittemplateoperator.php
autolinkx|autolinkautolink()inputezautolinkoperator.php
class_iconx|class_iconclass_icon()inputezwordtoimageoperator.php
classgroup_iconx|classgroup_iconclassgroup_icon()inputezwordtoimageoperator.php
content_structure_treex|content_structure_treecontent_structure_tree()ignores inputezcontentstructuretreeoperator.php
csp_noncex|csp_noncecsp_nonce()ignores inputexpcontentsecuritypolicyoperator.php
d18nx|d18nd18n()inputezi18noperator.php
exp_demo_modex|exp_demo_modeexp_demo_mode()ignores inputexpdemomodeoperator.php
exp_environmentx|exp_environmentexp_environment()ignores inputexpenvironmentoperator.php
exp_environment_badgex|exp_environment_badgeexp_environment_badge()ignores inputexpenvironmentoperator.php
ezmodulex|ezmoduleezmodule()ignores inputezmoduleoperator.php
ezpackagex|ezpackageezpackage()inputezpackageoperator.php
ezpreferencex|ezpreferenceezpreference()paramezkerneloperator.php
eztocx|eztoceztoc()ignores inputeztocoperator.php
flag_iconx|flag_iconflag_icon()inputezwordtoimageoperator.php
i18nx|i18ni18n()inputezi18noperator.php
iconx|iconicon()inputezwordtoimageoperator.php
icon_infox|icon_infoicon_info()ignores inputezwordtoimageoperator.php
installation_namex|installation_nameinstallation_name()ignores inputexpinstallationoperator.php
is_production_systemx|is_production_systemis_production_system()ignores inputexpinstallationoperator.php
language_switcherx|language_switcherlanguage_switcher()ignores inputezplanguageswitcheroperator.php
mimetype_iconx|mimetype_iconmimetype_icon()inputezwordtoimageoperator.php
module_paramsx|module_paramsmodule_params()ignores inputezmoduleparamsoperator.php
month_overviewx|month_overviewmonth_overview()inputezdateoperatorcollection.php
simpletagsx|simpletagssimpletags()inputezsimpletagsoperator.php
siteaccess_menux|siteaccess_menusiteaccess_menu()paramezpsiteaccessmenuoperator.php
siteaccess_menu_keyx|siteaccess_menu_keysiteaccess_menu_key()paramezpsiteaccessmenuoperator.php
siteaccess_urlx|siteaccess_urlsiteaccess_url()paramezpsiteaccessurloperator.php
topmenux|topmenutopmenu()ignores inputeztopmenuoperator.php
transfer_actionsx|transfer_actionstransfer_actions()ignores inputexpkerneltransferoperator.php
transfer_relatedx|transfer_relatedtransfer_related()ignores inputexpkerneltransferoperator.php
transfer_toolx|transfer_tooltransfer_tool()ignores inputexpkerneltransferoperator.php
transfer_toolsx|transfer_toolstransfer_tools()ignores inputexpkerneltransferoperator.php
treemenux|treemenutreemenu()ignores inputeztreemenuoperator.php
view_parameterx|view_parameterview_parameter()inputexpviewparameteroperator.php
wordtoimagex|wordtoimagewordtoimage()inputezwordtoimageoperator.php
x18nx|x18nx18n()inputezi18noperator.php

Template library (lib/)

OperatorFilter formFunction formInputClass file
absx|exp_absabs()parameztemplatearithmeticoperator.php
addcslashesx|addcslashesaddcslashes()inputeztemplatestringsoperator.php
addslashesx|addslashesaddslashes()inputeztemplatestringsoperator.php
andx|exp_andexp_and()parameztemplatelogicoperator.php
appendx|appendappend()inputeztemplatearrayoperator.php
arrayx|array[]inputeztemplatearrayoperator.php
array_appendx|array_appendarray_append()inputeztemplatearrayoperator.php
array_mergex|array_mergearray_merge()inputeztemplatearrayoperator.php
array_prependx|array_prependarray_prepend()inputeztemplatearrayoperator.php
array_sumx|array_sumarray_sum()inputeztemplatearrayoperator.php
attributex|attributeexp_attribute()inputeztemplateattributeoperator.php
begins_withx|begins_withbegins_with()inputeztemplatearrayoperator.php
bin2hexx|bin2hexbin2hex()inputeztemplatestringsoperator.php
breakx|breakbreak()inputeztemplatestringoperator.php
ceilx|ceilceil()parameztemplatearithmeticoperator.php
choosex|choosechoose()inputeztemplatelogicoperator.php
chrx|chrchr()inputeztemplatestringoperator.php
chunk_splitx|chunk_splitchunk_split()inputeztemplatestringsoperator.php
comparex|comparecompare()inputeztemplatearrayoperator.php
concatx|concatconcat()parameztemplatetextoperator.php
condx|condcond()ignores inputeztemplatecontroloperator.php
containsx|containscontains()inputeztemplatearrayoperator.php
convert_uudecodex|convert_uudecodeconvert_uudecode()inputeztemplatestringsoperator.php
convert_uuencodex|convert_uuencodeconvert_uuencode()inputeztemplatestringsoperator.php
countx|countcount()inputeztemplatearithmeticoperator.php
count_charsx|count_charscount_chars()inputeztemplatestringoperator.php
count_wordsx|count_wordscount_words()inputeztemplatestringoperator.php
crc32x|crc32crc32()inputeztemplatedigestoperator.php
currentdatex|currentdatecurrentdate()parameztemplatelocaleoperator.php
datetimex|datetimedatetime()inputeztemplatelocaleoperator.php
decx|decdec()parameztemplatearithmeticoperator.php
divx|divdiv()parameztemplatearithmeticoperator.php
downcasex|downcasedowncase()inputeztemplatestringoperator.php
dumpx|dumpexp_dump()inputeztemplateattributeoperator.php
ends_withx|ends_withends_with()inputeztemplatearrayoperator.php
eqx|eqeq()parameztemplatelogicoperator.php
exp_smarty_renderx|exp_smarty_renderexp_smarty_render()ignores inputexpsmartyoperator.php
exp_twig_renderx|exp_twig_renderexp_twig_render()ignores inputexptwigoperator.php
expinfox|expinfoexpinfo()parameztemplateexpinfooperator.php
explodex|explodeexplode()inputeztemplatearrayoperator.php
extractx|extractextract()inputeztemplatearrayoperator.php
extract_leftx|extract_leftextract_left()inputeztemplatearrayoperator.php
extract_rightx|extract_rightextract_right()inputeztemplatearrayoperator.php
falsex|exp_falsefalseparameztemplatelogicoperator.php
fetchx|fetchfetch()parameztemplateexecuteoperator.php
fetch_aliasx|fetch_aliasfetch_alias()parameztemplateexecuteoperator.php
first_setx|first_setfirst_set()ignores inputeztemplatecontroloperator.php
floatx|floatfloat()parameztemplatearithmeticoperator.php
floorx|floorfloor()parameztemplatearithmeticoperator.php
gex|gege()parameztemplatelogicoperator.php
get_classx|get_classget_class()parameztemplatetypeoperator.php
get_typex|get_typeget_type()parameztemplatetypeoperator.php
getenvx|getenvgetenv()parameztemplatephpoperator.php
gettimex|gettimegettime()inputeztemplatelocaleoperator.php
gtx|gtgt()parameztemplatelogicoperator.php
has_any_rolex|has_any_rolehas_any_role()ignores inputeztemplateroleoperator.php
has_policyx|has_policyhas_policy()ignores inputeztemplateroleoperator.php
has_policy_by_userx|has_policy_by_userhas_policy_by_user()ignores inputeztemplateroleoperator.php
has_rolex|has_rolehas_role()ignores inputeztemplateroleoperator.php
has_role_by_userx|has_role_by_userhas_role_by_user()ignores inputeztemplateroleoperator.php
has_role_by_user_idx|has_role_by_user_idhas_role_by_user_id()ignores inputeztemplateroleoperator.php
has_role_idx|has_role_idhas_role_id()ignores inputeztemplateroleoperator.php
hashx|hash{}inputeztemplatearrayoperator.php
hebrevx|hebrevhebrev()inputeztemplatestringsoperator.php
hex2binx|hex2binhex2bin()inputeztemplatestringsoperator.php
html_entity_decodex|html_entity_decodehtml_entity_decode()inputeztemplatestringsoperator.php
htmlentitiesx|htmlentitieshtmlentities()inputeztemplatestringsoperator.php
htmlspecialchars_decodex|htmlspecialchars_decodehtmlspecialchars_decode()inputeztemplatestringsoperator.php
imagefilex|imagefileimagefile()parameztemplateimageoperator.php
implodex|implodeimplode()inputeztemplatearrayoperator.php
incx|incinc()parameztemplatearithmeticoperator.php
indentx|indentindent()inputeztemplatetextoperator.php
insertx|insertinsert()inputeztemplatearrayoperator.php
intx|intint()parameztemplatearithmeticoperator.php
is_arrayx|is_arrayis_array()parameztemplatetypeoperator.php
is_booleanx|is_booleanis_boolean()parameztemplatetypeoperator.php
is_classx|is_classis_class()parameztemplatetypeoperator.php
is_floatx|is_floatis_float()parameztemplatetypeoperator.php
is_integerx|is_integeris_integer()parameztemplatetypeoperator.php
is_nullx|is_nullis_null()parameztemplatetypeoperator.php
is_numericx|is_numericis_numeric()parameztemplatetypeoperator.php
is_objectx|is_objectis_object()parameztemplatetypeoperator.php
is_setx|is_setis_set()parameztemplatetypeoperator.php
is_stringx|is_stringis_string()parameztemplatetypeoperator.php
is_unsetx|is_unsetis_unset()parameztemplatetypeoperator.php
l10nx|l10nl10n()inputeztemplatelocaleoperator.php
lcfirstx|lcfirstlcfirst()inputeztemplatestringsoperator.php
lex|lele()parameztemplatelogicoperator.php
levenshteinx|levenshteinlevenshtein()inputeztemplatestringsoperator.php
localex|localelocale()inputeztemplatelocaleoperator.php
ltx|ltlt()parameztemplatelogicoperator.php
ltrimx|ltrimltrim()inputeztemplatestringsoperator.php
makedatex|makedatemakedate()inputeztemplatelocaleoperator.php
maketimex|maketimemaketime()inputeztemplatelocaleoperator.php
maxx|maxexp_max()parameztemplatearithmeticoperator.php
md5x|md5md5()inputeztemplatedigestoperator.php
mergex|exp_mergemerge()inputeztemplatearrayoperator.php
metaphonex|metaphonemetaphone()inputeztemplatestringsoperator.php
minx|minexp_min()parameztemplatearithmeticoperator.php
modx|modmod()parameztemplatearithmeticoperator.php
mulx|mulmul()parameztemplatearithmeticoperator.php
nex|nene()parameztemplatelogicoperator.php
nl2brx|exp_nl2brnl2br()inputeztemplatephpoperator.php
notx|exp_notexp_not()parameztemplatelogicoperator.php
nullx|exp_nullexp_null()inputeztemplatelogicoperator.php
number_formatx|exp_number_formatnumber_format()inputeztemplatestringsoperator.php
orx|exp_orexp_or()parameztemplatelogicoperator.php
ordx|ordord()inputeztemplatestringoperator.php
padx|padpad()inputeztemplatestringoperator.php
pdfx|pdfpdf()ignores inputezpdf.php
prependx|prependprepend()inputeztemplatearrayoperator.php
quoted_printable_decodex|quoted_printable_decodequoted_printable_decode()inputeztemplatestringsoperator.php
quoted_printable_encodex|quoted_printable_encodequoted_printable_encode()inputeztemplatestringsoperator.php
quotemetax|quotemetaquotemeta()inputeztemplatestringsoperator.php
randx|randrand()parameztemplatearithmeticoperator.php
rawurldecodex|rawurldecoderawurldecode()parameztemplatephpoperator.php
rawurlencodex|rawurlencoderawurlencode()parameztemplatephpoperator.php
removex|removeremove()inputeztemplatearrayoperator.php
repeatx|repeatrepeat()inputeztemplatearrayoperator.php
replacex|exp_replacereplace()inputeztemplatearrayoperator.php
reversex|exp_reversereverse()inputeztemplatearrayoperator.php
ristringx|ristringristring()inputeztemplatestringsoperator.php
romanx|romanroman()parameztemplatearithmeticoperator.php
rot13x|rot13rot13()inputeztemplatedigestoperator.php
roundx|exp_roundround()parameztemplatearithmeticoperator.php
rstringx|rstringrstring()inputeztemplatestringsoperator.php
rtrimx|rtrimrtrim()inputeztemplatestringsoperator.php
serializex|serializeserialize()parameztemplatephpoperator.php
shortenx|shortenshorten()inputeztemplatestringoperator.php
six|sisi()inputeztemplateunitoperator.php
similar_textx|similar_textsimilar_text()inputeztemplatestringsoperator.php
simplifyx|simplifysimplify()inputeztemplatestringoperator.php
soundexx|soundexsoundex()inputeztemplatestringsoperator.php
sprintfx|sprintfsprintf()inputeztemplatestringsoperator.php
str_containsx|str_containsstr_contains()inputeztemplatestringsoperator.php
str_ends_withx|str_ends_withstr_ends_with()inputeztemplatestringsoperator.php
str_getcsvx|str_getcsvstr_getcsv()inputeztemplatestringsoperator.php
str_shufflex|str_shufflestr_shuffle()inputeztemplatestringsoperator.php
str_splitx|str_splitstr_split()inputeztemplatestringsoperator.php
str_starts_withx|str_starts_withstr_starts_with()inputeztemplatestringsoperator.php
str_word_countx|str_word_countstr_word_count()inputeztemplatestringsoperator.php
strcasecmpx|strcasecmpstrcasecmp()inputeztemplatestringsoperator.php
strcmpx|strcmpstrcmp()inputeztemplatestringsoperator.php
strcollx|strcollstrcoll()inputeztemplatestringsoperator.php
strcspnx|strcspnstrcspn()inputeztemplatestringsoperator.php
strip_tagsx|strip_tagsstrip_tags()parameztemplatephpoperator.php
stripcslashesx|stripcslashesstripcslashes()inputeztemplatestringsoperator.php
striposx|striposstripos()inputeztemplatestringsoperator.php
stripslashesx|stripslashesstripslashes()inputeztemplatestringsoperator.php
stristrx|stristrstristr()inputeztemplatestringsoperator.php
strlenx|strlenstrlen()inputeztemplatestringsoperator.php
strnatcasecmpx|strnatcasecmpstrnatcasecmp()inputeztemplatestringsoperator.php
strnatcmpx|strnatcmpstrnatcmp()inputeztemplatestringsoperator.php
strncasecmpx|strncasecmpstrncasecmp()inputeztemplatestringsoperator.php
strncmpx|strncmpstrncmp()inputeztemplatestringsoperator.php
strpbrkx|strpbrkstrpbrk()inputeztemplatestringsoperator.php
strposx|strposstrpos()inputeztemplatestringsoperator.php
strrchrx|strrchrstrrchr()inputeztemplatestringsoperator.php
strriposx|strriposstrripos()inputeztemplatestringsoperator.php
strrposx|strrposstrrpos()inputeztemplatestringsoperator.php
strspnx|strspnstrspn()inputeztemplatestringsoperator.php
strstrx|strstrstrstr()inputeztemplatestringsoperator.php
strtokx|strtokstrtok()inputeztemplatestringsoperator.php
strtrx|strtrstrtr()inputeztemplatestringsoperator.php
subx|subsub()parameztemplatearithmeticoperator.php
substrx|substrsubstr()inputeztemplatestringsoperator.php
substr_comparex|substr_comparesubstr_compare()inputeztemplatestringsoperator.php
substr_countx|substr_countsubstr_count()inputeztemplatestringsoperator.php
substr_replacex|substr_replacesubstr_replace()inputeztemplatestringsoperator.php
sumx|sumsum()parameztemplatearithmeticoperator.php
texttoimagex|texttoimagetexttoimage()inputeztemplateimageoperator.php
trimx|exp_trimtrim()inputeztemplatestringoperator.php
truex|exp_truetrueparameztemplatelogicoperator.php
uniquex|uniqueunique()inputeztemplatearrayoperator.php
unserializex|unserializeunserialize()parameztemplatephpoperator.php
upcasex|upcaseupcase()inputeztemplatestringoperator.php
upfirstx|upfirstupfirst()inputeztemplatestringoperator.php
upwordx|upwordupword()inputeztemplatestringoperator.php
urldecodex|urldecodeurldecode()parameztemplatephpoperator.php
urlencodex|urlencodeurlencode()parameztemplatephpoperator.php
vsprintfx|vsprintfvsprintf()inputeztemplatestringsoperator.php
washx|washwash()inputeztemplatestringoperator.php
wrapx|wrapwrap()inputeztemplatestringoperator.php

Extension ezjscore

OperatorFilter formFunction formInputClass file
ezcssx|ezcssezcss()inputezjscpackertemplatefunctions.php
ezcss_loadx|ezcss_loadezcss_load()inputezjscpackertemplatefunctions.php
ezcss_requirex|ezcss_requireezcss_require()inputezjscpackertemplatefunctions.php
ezcssfilesx|ezcssfilesezcssfiles()inputezjscpackertemplatefunctions.php
ezscriptx|ezscriptezscript()inputezjscpackertemplatefunctions.php
ezscript_loadx|ezscript_loadezscript_load()inputezjscpackertemplatefunctions.php
ezscript_requirex|ezscript_requireezscript_require()inputezjscpackertemplatefunctions.php
ezscriptfilesx|ezscriptfilesezscriptfiles()inputezjscpackertemplatefunctions.php
has_access_to_limitationx|has_access_to_limitationhas_access_to_limitation()inputezjscaccesstemplatefunctions.php
json_encodex|exp_json_encodejson_encode()inputezjscencodingtemplatefunctions.php
node_encodex|node_encodenode_encode()inputezjscencodingtemplatefunctions.php
xml_encodex|xml_encodexml_encode()inputezjscencodingtemplatefunctions.php

Extension ezoe

OperatorFilter formFunction formInputClass file
ezoe_ini_sectionx|ezoe_ini_sectionezoe_ini_section()inputezoetemplateutils.php

Extension ezstarrating

OperatorFilter formFunction formInputClass file
fetch_by_starratingx|fetch_by_starratingfetch_by_starrating()inputezsrtemplateoperators.php
fetch_starrating_datax|fetch_starrating_datafetch_starrating_data()inputezsrtemplateoperators.php
fetch_starrating_statsx|fetch_starrating_statsfetch_starrating_stats()inputezsrtemplateoperators.php

Extension eztags

OperatorFilter formFunction formInputClass file
eztags_parent_stringx|eztags_parent_stringeztags_parent_string()inputeztagstemplatefunctions.php
eztagscloudx|eztagscloudeztagscloud()inputeztagscloud.php
latest_tagsx|latest_tagslatest_tags()inputeztagstemplatefunctions.php
tag_iconx|tag_icontag_icon()inputeztagstemplatefunctions.php
user_limitationsx|user_limitationsuser_limitations()inputeztagstemplatefunctions.php

Extension ezurlmultisite

OperatorFilter formFunction formInputClass file
exturlx|exturlexturl()inputezurlmultisiteurloperator.php
ezdesignx|ezdesignezdesign()inputezurlmultisiteurloperator.php
ezhttpx|ezhttpezhttp()ignores inputezurlmultisiteurloperator.php
ezhttp_hasvariablex|ezhttp_hasvariableezhttp_hasvariable()ignores inputezurlmultisiteurloperator.php
ezimagex|ezimageezimage()inputezurlmultisiteurloperator.php
ezinix|eziniezini()paramezurlmultisiteurloperator.php
ezini_hasvariablex|ezini_hasvariableezini_hasvariable()paramezurlmultisiteurloperator.php
ezrootx|ezrootezroot()inputezurlmultisiteurloperator.php
ezsysx|ezsysezsys()inputezurlmultisiteurloperator.php
ezurlx|ezurlezurl()inputezurlmultisiteurloperator.php
ezurl_pathx|ezurl_pathezurl_path()inputezurlmultisiteoperator.php
ezurl_rootsx|ezurl_rootsezurl_roots()inputezurlmultisiteoperator.php
ezurl_siteaccessx|ezurl_siteaccessezurl_siteaccess()inputezurlmultisiteoperator.php

Extension ezwebin

OperatorFilter formFunction formInputClass file
ezarchivex|ezarchiveezarchive()inputezarchive.php
ezkeywordlistx|ezkeywordlistezkeywordlist()inputezkeywordlist.php
ezpagedatax|ezpagedataezpagedata()inputezpagedata.php
ezpagedata_appendx|ezpagedata_appendezpagedata_append()inputezpagedata.php
ezpagedata_setx|ezpagedata_setezpagedata_set()inputezpagedata.php
eztagcloudx|eztagcloudeztagcloud()inputeztagcloud.php

Extension ezwt

OperatorFilter formFunction formInputClass file
ezcreateclasslistgroupsx|ezcreateclasslistgroupsezcreateclasslistgroups()inputezcreateclasslistgroups.php

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x