mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-02-12 06:56:24 +00:00
![pies](/assets/img/avatar_default.png)
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@239 3807eeeb-6ff5-0310-8944-8be069107fe0
36 lines
No EOL
996 B
PHP
36 lines
No EOL
996 B
PHP
<?PHP
|
|
//////////////////////////////////////////////////////////////////////////
|
|
// + $Id$
|
|
// +------------------------------------------------------------------+ //
|
|
// + Cake <https://developers.nextco.com/cake/> + //
|
|
// + Copyright: (c) 2005, Cake Authors/Developers + //
|
|
// +------------------------------------------------------------------+ //
|
|
// + Licensed under The MIT License + //
|
|
//////////////////////////////////////////////////////////////////////////
|
|
|
|
class PagesController extends PagesHelper {
|
|
|
|
/**
|
|
* Displays a view
|
|
*
|
|
* @package cake
|
|
* @subpackage cake.app
|
|
*/
|
|
function display () {
|
|
|
|
if (!func_num_args())
|
|
$this->redirect('/');
|
|
|
|
$path = func_get_args();
|
|
if (!count($path))
|
|
$this->redirect('/');
|
|
|
|
$this->set('page', $path[0]);
|
|
$this->set('subpage', empty($path[1])? null: $path[1]);
|
|
$this->set('title', ucfirst($path[count($path)-1]));
|
|
$this->render(join('/', $path));
|
|
}
|
|
|
|
}
|
|
|
|
?>
|