本文整理汇总了PHP中JApplicationCms::allowCache方法的典型用法代码示例。如果您正苦于以下问题:PHP JApplicationCms::allowCache方法的具体用法?PHP JApplicationCms::allowCache怎么用?PHP JApplicationCms::allowCache使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类JApplicationCms
的用法示例。
在下文中一共展示了JApplicationCms::allowCache方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: display
/**
* Execute and display a template script.
*
* @param string $tpl The name of the template file to parse; automatically searches through the template paths.
*
* @return mixed A string if successful, otherwise a Error object.
*
* @since 3.6
*/
public function display($tpl = null)
{
// Do not allow cache
$this->app->allowCache(false);
$foldersModel = $this->getFoldersModel();
$currentFolder = $foldersModel->getCurrentFolder();
$folders = $foldersModel->getFolders();
$filesModel = $this->getFilesModel();
$files = $filesModel->setFileFilter($this->getFileFilter())->getFiles();
$state = $this->get('state');
$this->currentFolder = $currentFolder;
$this->files = $files;
$this->folders = $folders;
$this->state = $state;
return parent::display($tpl);
}
示例2: noCache
/**
* {@inheritdoc}
*/
public function noCache()
{
$this->_app->allowCache(false);
$this->_noCache();
}