public function InstapageCmsPluginViewModel::init in Instapage plugin 8.3
Same name and namespace in other branches
- 7.3 core/models/InstapageCmsPluginViewModel.php \InstapageCmsPluginViewModel::init()
Initiates the templates. Sets the templates attributes.
Parameters
array $templates Templates to initiate.:
array $attributes Attributes to pass to the templates.:
File
- core/
models/ InstapageCmsPluginViewModel.php, line 57
Class
- InstapageCmsPluginViewModel
- Class responsible for displaying a template files.
Code
public function init($templates = null, $attributes = null) {
if ($attributes) {
foreach ($attributes as $key => $value) {
$this->templateData[$key] = $value;
}
}
$this->templates = $templates;
}