$optional_attributes
$optional_attributes : array
Array of names of optional attribute required by tag use array('_any') if there is no restriction of attributes names
Smarty Internal Plugin Compile Object Block Function Class
compile(array $args, \Smarty_Internal_TemplateCompilerBase $compiler, array $parameter, string $tag, string $function = null) : string
Compiles code for the execution of block plugin
array | $args | array with attributes from parser |
\Smarty_Internal_TemplateCompilerBase | $compiler | compiler object |
array | $parameter | array with compilation parameter |
string | $tag | name of block plugin |
string | $function | PHP function name |
compiled code
setup(\Smarty_Internal_TemplateCompilerBase $compiler, array $_attr, string $tag, string $method) : array
Setup callback and parameter array
\Smarty_Internal_TemplateCompilerBase | $compiler | |
array | $_attr | attributes |
string | $tag | |
string | $method |
getAttributes(object $compiler, array $attributes) : array
This function checks if the attributes passed are valid The attributes passed for the tag to compile are checked against the list of required and optional attributes. Required attributes must be present. Optional attributes are check against the corresponding list. The keyword '_any' specifies that any attribute will be accepted as valid
object | $compiler | compiler object |
array | $attributes | attributes applied to the tag |
of mapped attributes for further processing
closeTag(object $compiler, array|string $expectedTag) : mixed
Pop closing tag Raise an error if this stack-top doesn't match with expected opening tags
object | $compiler | compiler object |
array|string | $expectedTag | the expected opening tag names |
any type the opening tag's name or saved data