Returns the variables to bind to the template when rendering.
public getTemplateVars ( array $override = [] ) : array | ||
$override | array | Template variable override values. Mainly useful when including View templates in other templates. |
return | array |
/** * See {@link View::getTemplateVars()}. */ public function getTemplateVars($override = array()) { $this->templateVars['implView'] = $this->innerView; $this->templateVars['cssIdentifier'] = $this->cssIdentifier; $this->templateVars['cssClass'] = $this->cssClass; $this->templateVars['jsClass'] = $this->jsClass; $this->templateVars['jsNamespace'] = $this->jsNamespace; $this->templateVars['implOverride'] = $override; $innerTemplateVars = $this->innerView->getTemplateVars($override); $this->templateVars['clientSideProperties'] = array(); foreach ($this->getClientSideProperties() as $name) { $this->templateVars['clientSideProperties'][$name] = $innerTemplateVars[$name]; } $this->templateVars['clientSideParameters'] = array(); foreach ($this->getClientSideParameters() as $name) { $this->templateVars['clientSideParameters'][$name] = $innerTemplateVars[$name]; } return parent::getTemplateVars($override); }