Note that you should not use mark_raw in templates because it can make security hole easily just like as type casts in C. If you want to generate HTML components dynamically, e.g. by HTML form builders, application code should be responsible to make strings as marked raw.

Methods

When $var is an object instance, you can call its methods with the dot operator.

There is a limitation that you cannot pass variables to the cascade keyword, because template cascading is statically processed.

Macro blocks

Macros are supported, which are called in the same way as functions and return a raw string. Macros returns what their bodies render, so they cannot return references nor objects including other macros.