本文整理匯總了PHP中Phalcon\Mvc\View::_engineRender方法的典型用法代碼示例。如果您正苦於以下問題:PHP View::_engineRender方法的具體用法?PHP View::_engineRender怎麽用?PHP View::_engineRender使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Phalcon\Mvc\View
的用法示例。
在下文中一共展示了View::_engineRender方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: _engineRender
protected function _engineRender($engines, $viewPath, $silence, $mustClean, BackendInterface $cache = null)
{
$silence = $silence && !$this->config['debug'];
$this->_options['debug_wrapper'] = $this->config['debug'] ? $viewPath == $this->_mainView ? null : $this->getDebugWrapper($viewPath) : null;
$viewPath == $this->_mainView or $viewPath = $this->getAbsoluteViewPath($viewPath);
parent::_engineRender($engines, $viewPath, $silence, $mustClean, $cache);
}
示例2: _engineRender
protected function _engineRender($engines, $viewShortPath, $silence, $mustClean, \Phalcon\Cache\BackendInterface $cache = null)
{
// $silence = false;
// $this->log->info("engines render...".$this->renderCounter."...viewShortPath:$viewShortPath </br>\n");
// $basePath = $this->getBasePath();
//如果設置basePath,使用短路徑查找.
//則目錄路徑 = view->basePath + $view->viewPath + $viewShortPath
//因為viewPath是根據Controller/Action動態設置的,故此,根據renderCounter判斷是否為action的匹配
//非action定位,把ViewsDir設置為空
if ($this->renderCounter > 0) {
$this->cleanViewsDir();
}
$this->renderCounter += 1;
return parent::_engineRender($engines, $viewShortPath, $silence, $mustClean, $cache);
}
示例3: _engineRender
/**
* Override of the _engineRender function that dynamicall resets the cascade paths
*
* @return void
* @author Neil Brayfield
**/
protected function _engineRender($engines, $viewPath, $silence, $mustClean, BackendInterface $cache = null)
{
// get original so it can be restored
$this->setViewsDir($this->getCascadeDefault());
// Check directories for existing views
$cascadePaths = $this->getCascadePaths();
if ($cascadePaths) {
// check default
if (!$this->exists($viewPath)) {
foreach ($cascadePaths as $path) {
$this->setViewsDir($path . 'views/');
if ($this->exists($viewPath)) {
break;
}
}
}
}
parent::_engineRender($engines, $viewPath, $silence, $mustClean, $cache);
}