protected function evaluateTemplate(array &$forceParams)
{
// If the engine returned raw content, return the raw content immediately
if ($this->_tempFilePath['type'] == 'raw') {
return $this->_tempFilePath['content'];
}
if (substr($this->_tempFilePath['content'], 0, 4) == 'raw|') {
return substr($this->_tempFilePath['content'], 4);
}
$obLevel = ob_get_level();
ob_start();
// We'll evaluate the contents of the view inside a try/catch block so we can
// flush out any stray output that might get out before an error occurs or
// an exception is thrown. This prevents any partial views from leaking.
try {
$this->includeTemplateFile($forceParams);
} catch (\Exception $e) {
$this->handleViewException($e, $obLevel);
}
return ob_get_clean();
}