Learning: Learning: Template Comments

eZ publish Template Comment Syntax

From: 3.4 Doc Site | http://ez.no/ez_publish/documentation/the_template_language/comments

Comments

Just like in almost any programming language, comments can be used to add explanations, descriptions, etc.

Template comments are not displayed in the resulting (X)HTML output that is generated by eZ publish.

Commented chunks of template text/code will not be interpreted by the template engine.

There is only one way to add template comments, and that is by encapsulating the desired comment by a matching pair of the “{*” and “*}” sequence of characters.

Clearly, a template comment is just like any other template code except that the curly brackets are accompanied by adjacent asterisks. It is possible to comment both single and multiple lines of text/code. Nesting of comments is not supported. In other words, it is not possible to comment a comment.
The following examples demonstrate the use of comments:

Single-line comment
{* This is a comment. *}

Will not produce any output.

Multi-line comment
{* This is a comment 

  that spans across
  several lines in
  the template file. *}

Will not produce any output.

Nested comments
{* {* Nested comments are not supported! *} This text will be displayed. *} 

The following output will be displayed:

This text will be displayed.