-
Notifications
You must be signed in to change notification settings - Fork 0
View
linchpin edited this page Feb 22, 2023
·
10 revisions
View Class
- Full name:
\CourierNotices\Core\View
Variables for substitution in templates
protected array $variables
View constructor
public __construct(null $config = null): mixed
Parameters:
Parameter | Type | Description |
---|---|---|
$config |
null | The configuration. |
Load all assets on boot-up
public load_assets(): void
Render HTML file
public render(string $file, string $view_dir = null): void
Parameters:
Parameter | Type | Description |
---|---|---|
$file |
string | File to get HTML string. |
$view_dir |
string | View directory. |
Assign variable for substitution in templates.
public assign(string $variable, mixed $value): void
Parameters:
Parameter | Type | Description |
---|---|---|
$variable |
string | Name variable to assign. |
$value |
mixed | Value variable for assign. |
Get HTML from file
public get_text_view(string $file, string $view_dir = null): string
Parameters:
Parameter | Type | Description |
---|---|---|
$file |
string | File to get HTML string. |
$view_dir |
string | View directory. |
Return Value:
$html HTML output as string
Reset the variables
protected init_assignments(): mixed
Automatically generated from source code comments on 2023-02-22 using phpDocumentor and saggre/phpdocumentor-markdown