ITemplate
in
Tags
Table of Contents
Methods
- append() : void
- Appends a variable
- assign() : void
- Assign variables
- fetchPage() : string
- Process the template
- printPage() : void
- Proceed the template and print its output.
Methods
append()
Appends a variable
public
append(string $key, mixed $value) : void
This function assigns a variable in an array context. If the key already exists, the value will be appended. It can be accessed via $_[$key][$position] in the template.
Parameters
- $key : string
- $value : mixed
assign()
Assign variables
public
assign(string $key, mixed $value) : void
This function assigns a variable. It can be accessed via $_[$key] in the template.
If the key existed before, it will be overwritten
Parameters
- $key : string
- $value : mixed
Tags
fetchPage()
Process the template
public
fetchPage([array<string|int, mixed>|null $additionalParams = null ]) : string
Parameters
- $additionalParams : array<string|int, mixed>|null = null
Tags
Return values
stringprintPage()
Proceed the template and print its output.
public
printPage() : void