📚 Looking for current Exponential documentation? This site contains legacy SDK & API reference docs (eZ Publish era). For up-to-date 2026 product documentation, visit doc.exponential.earth.

  eztemplate / basic_functions  

<< Operators  Operator list >> 

Functions

Functions are template tags that perform code on a set of sub-children, or work stand-alone. Both functions and operators perform code but there are some differences.

Functions take named parameters and can work on sub children elements, that can be functions or text. Operators work like Unix pipes where the data is input in one end, processed and output to either a new operator or to the output. Operators also take sequenced parameters to modify their behaviour. Mixing operators and variable types both as parameter and as input works.

Most functions are stand-alone classes that can be replaced or modified. One internal functions is literal which must be done internally due to parsing issues*.

* A change in the parser might be made to allow for an external literal function.

This example shows usage of the switch function to show conditional content.

{switch match=$match1}
  {case match=1}Matched 1{/case}
  {case match=2}Matched 2{/case}
  {case}Matched default{/case}
{/switch}

Exponential Copyright © 1998 - 2026 7x