*** # View View Class * Full name: `\CourierNotices\Core\View` ## Properties ### variables Variables for substitution in templates ```php protected array $variables ``` *** ## Methods ### __construct View constructor ```php public __construct(null $config = null): mixed ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$config` | **null** | The configuration. | *** ### load_assets Load all assets on boot-up ```php public load_assets(): void ``` *** ### render Render HTML file ```php 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 Assign variable for substitution in templates. ```php public assign(string $variable, mixed $value): void ``` **Parameters:** | Parameter | Type | Description | |-----------|------|-------------| | `$variable` | **string** | Name variable to assign. | | `$value` | **mixed** | Value variable for assign. | *** ### get_text_view Get HTML from file ```php 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 *** ### init_assignments Reset the variables ```php protected init_assignments(): mixed ``` *** *** > Automatically generated on 2024-08-26