exit

Terminates the current template.

Syntax

exit

Input

N/A

Example

Template:
{' Quit if x is less than zero}
 {x=-11}
 {if(x < 0.0)}
   {echo("Attempting ln of negative number")}
   {exit}
 {endif}
 {ln(x)}

Comments

The exit statement performs two functions:

When exit is encountered in a stand-alone template, Templex stops.

When exit is encountered in a template called by another template (see include), Templex returns to the instruction immediately following include in the calling template.