|
eZ Publish
[4.2]
|
Includes external template code using function "include". More...
Public Member Functions | |
| eZTemplateIncludeFunction ($inc_name="include") | |
| functionList () | |
| functionTemplateHints () | |
| hasChildren () | |
| process ($tpl, &$textElements, $functionName, $functionChildren, $functionParameters, $functionPlacement, $rootNamespace, $currentNamespace) | |
| templateNodeTransformation ($functionName, &$node, $tpl, $parameters, $privateData) | |
Static Public Member Functions | |
| static | handleInclude (&$textElements, &$uri, $tpl, $rootNamespace, $name) |
Public Attributes | |
| $IncludeName | |
| The name of the include function. | |
Includes external template code using function "include".
Allows the template designer to include another template file dynamically. This allows for reuse of commonly used template code. The new template file will loaded into the current namespace or a namspace specified by the template designer, any extra parameters to this function is set as template variables for the template file using the newly aquired namespace.
// Example template code
{include uri=file:myfile.tpl}
{include name=new_namespace uri=/etc/test.tpl}
Definition at line 52 of file eztemplateincludefunction.php.
| eZTemplateIncludeFunction::eZTemplateIncludeFunction | ( | $ | inc_name = "include" | ) |
Initializes the function with the function name $inc_name.
Definition at line 57 of file eztemplateincludefunction.php.
| eZTemplateIncludeFunction::functionList | ( | ) |
Returns an array of the function names, required for eZTemplate::registerFunctions.
Definition at line 65 of file eztemplateincludefunction.php.
| eZTemplateIncludeFunction::functionTemplateHints | ( | ) |
Definition at line 70 of file eztemplateincludefunction.php.
| static eZTemplateIncludeFunction::handleInclude | ( | &$ | textElements, |
| &$ | uri, | ||
| $ | tpl, | ||
| $ | rootNamespace, | ||
| $ | name | ||
| ) | [static] |
Takes care of loading the template file and set it in the $text parameter.
Definition at line 221 of file eztemplateincludefunction.php.
Referenced by eZTemplate\appendElementText(), process(), and eZXMLOutputHandler\renderTag().
| eZTemplateIncludeFunction::hasChildren | ( | ) |
Returns false, telling the template parser that this is a single tag.
Definition at line 229 of file eztemplateincludefunction.php.
| eZTemplateIncludeFunction::process | ( | $ | tpl, |
| &$ | textElements, | ||
| $ | functionName, | ||
| $ | functionChildren, | ||
| $ | functionParameters, | ||
| $ | functionPlacement, | ||
| $ | rootNamespace, | ||
| $ | currentNamespace | ||
| ) |
Loads the file specified in the parameter "uri" with namespace "name".
Definition at line 156 of file eztemplateincludefunction.php.
| eZTemplateIncludeFunction::templateNodeTransformation | ( | $ | functionName, |
| &$ | node, | ||
| $ | tpl, | ||
| $ | parameters, | ||
| $ | privateData | ||
| ) |
Definition at line 79 of file eztemplateincludefunction.php.
| eZTemplateIncludeFunction::$IncludeName |
The name of the include function.
Definition at line 236 of file eztemplateincludefunction.php.