Added getting site config from DB

This commit is contained in:
Deon George
2011-09-29 17:13:32 +10:00
parent b6802e4b5d
commit 147d035e46
6 changed files with 77 additions and 40 deletions

View File

@@ -11,6 +11,18 @@
* @license http://dev.leenooks.net/license.html
*/
class Controller_TemplateDefault extends Controller_lnApp_TemplateDefault {
protected function _headimages() {
// This is where we should be able to change our country
// @todo To implement
$co = Config::instance()->so->country;
HeadImages::add(array(
'img'=>sprintf('img/country/%s.png',strtolower($co->two_code)),
'attrs'=>array('onclick'=>"target='_blank';",'title'=>$co->display('name'))
));
return HeadImages::factory();
}
protected function _left() {
if ($this->template->left)
return $this->template->left;