$suppressNocacheProcessing
$suppressNocacheProcessing : boolean
suppress generation of nocache code
Main abstract compiler class
$template : \Smarty_Internal_Template
current template
compileTemplate(\Smarty_Internal_Template $template) : boolean
Method to compile a Smarty template
\Smarty_Internal_Template | $template | template object to compile |
true if compiling succeeded, false if it failed
compileTag(string $tag, array $args, array $parameter = array()) : string
Compile Tag
This is a call back from the lexer/parser It executes the required compile plugin for the Smarty tag
string | $tag | tag name |
array | $args | array with tag attributes |
array | $parameter | array with compilation parameter |
compiled code
callTagCompiler(string $tag, array $args, mixed $param1 = null, mixed $param2 = null, mixed $param3 = null) : string
lazy loads internal compile plugin for tag and calls the compile methode
compile objects cached for reuse. class name format: Smarty_Internal_Compile_TagName plugin filename format: Smarty_Internal_Tagname.php
string | $tag | tag name |
array | $args | list of tag attributes |
mixed | $param1 | optional parameter |
mixed | $param2 | optional parameter |
mixed | $param3 | optional parameter |
compiled code
processNocacheCode(string $content, boolean $is_code) : string
Inject inline code for nocache template sections
This method gets the content of each template element from the parser. If the content is compiled code and it should be not cached the code is injected into the rendered output.
string | $content | content of template element |
boolean | $is_code | true if content is compiled code |
content
trigger_template_error(string $args = null, string $line = null)
display compiler error messages without dying
If parameter $args is empty it is a parser detected syntax error. In this case the parser is called to obtain information about expected tokens.
If parameter $args contains a string this is used as error message
string | $args | individual error message or null |
string | $line | line-number |
when an unexpected token is found