The templates are the language of Smarty. These are the files that the designers work with. They're basically pages made up of static content interspersed with template markup tags. These tags are placeholders for variables or blocks of logic.
All Smarty template tags are enclosed within delimiters. By default, these delimiters are { and }, but they can be changed.
For these examples, we will assume that you are using the default delimiters. In Smarty, all content outside of delimiters is displayed as static content, or unchanged. When Smarty encounters template tags, it attempts to interpret them, and displays the appropriate output in their place.
Template comments are surrounded by asterisks, and that is surrounded by the delimiter tags like so: {* this is a comment *} Smarty comments are not displayed in the final output of the template. They are used mainly for making the templates more understandable.
Each Smarty tag either prints a variable or invokes some sort of function. Functions are processed and displayed by enclosing the function and its attributes into delimiters like so: {funcname attr1="val" attr2="val"}.
Both built-in functions and custom functions have the same syntax in the templates. Built-in functions are the inner workings of Smarty, such as if, section and strip. They cannot be modified. Custom functions are additional functions implemented via plugins. They can be modified to your liking, or you can add new ones. html_options and html_select_date are examples of custom functions.
Most of the functions take attributes that specify or modify their behavior. Attributes to Smarty functions are much like HTML attributes. Static values don't have to be enclosed in quotes, but it is recommended for literal strings. Variables may also be used, and should not be in quotes.
Some attributes require boolean values (true or false). These can be specified as either unquoted true, on, and yes, or false, off, and no.