aboutsummaryrefslogtreecommitdiffstats
path: root/MainController.php
diff options
context:
space:
mode:
authorFilipp Lepalaan <filipp@mac.com>2011-05-18 15:27:10 +0300
committerFilipp Lepalaan <filipp@mac.com>2011-05-18 15:27:10 +0300
commitdbbb551bcc3744bf09109fdb238f3e0f297775d4 (patch)
treed4cf3441bd1f7b9e0e7eb3fceea2ad42032e9e12 /MainController.php
parentc63171e653c7bca1f8b23dede30e60d398de35ae (diff)
downloadmain-dbbb551bcc3744bf09109fdb238f3e0f297775d4.tar.gz
main-dbbb551bcc3744bf09109fdb238f3e0f297775d4.tar.bz2
main-dbbb551bcc3744bf09109fdb238f3e0f297775d4.zip
MainController.php
set different template with ->template
Diffstat (limited to 'MainController.php')
-rw-r--r--MainController.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/MainController.php b/MainController.php
index da27b81..c654ab0 100644
--- a/MainController.php
+++ b/MainController.php
@@ -17,7 +17,8 @@ class MainController
public $view; // Where to store the data to be rendered
public $pageTitle = ''; // Title of the rendered page
- public $defaultAction = ''; // Method to run when none specified
+ protected $template = 'default'; // The base template for this controller (view)
+ private $defaultAction = ''; // Method to run when none specified
const OrderBy = ''; // which column to order the results by
const HasMany = '';
@@ -395,7 +396,7 @@ class MainController
$c = strtolower($this->class);
}
- $template = '../system/views/default.'.$type;
+ $template = '../system/views/'.$this->template.'.'.$type;
$file = "../system/views/{$c}/{$view}.{$type}";
if (!is_file($file)) {