PageRenderTime 37ms CodeModel.GetById 29ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 0ms

/framework/core/gui/GuiSmarty3.php

http://zoop.googlecode.com/
PHP | 41 lines | 19 code | 7 blank | 15 comment | 1 complexity | 5898b7616b0de3a29460b35f92e57ddf MD5 | raw file
 1<?php
 2/**
 3 * Object extends the Smarty templating system to allow easy separation of business and
 4 * presentation logic
 5 *
 6 */
 7class GuiSmarty3 extends Smarty
 8{
 9	function __construct()
10	{
11		$config = GuiModule::sGetConfig();
12		$tmpPath = Zoop::getTmpDir();
13		
14		//	call the parent contructor
15		parent::__construct();
16		$this->template_dir = array();
17   		
18   		//	set the default for the base template dir
19		//	this should be using the new config stuff, not defines
20   		if(!defined("gui_template_dir") )
21   			define("gui_template_dir", app_dir . "/templates");
22   		
23   		//	set the standard template directory and any others registerd with zoop
24   		$this->addTemplateDir(gui_template_dir);
25		
26		//	set the compile directory
27		$this->setCompileDir($tmpPath . "/smarty2");
28		
29		//	set the cache_dir directory
30		//	what does this even do?  I'm pretty sure that is not set up
31		$this->setCacheDir($tmpPath . "/guicache");
32		
33		//	set the config directory
34		//	what does this even do?  I'm pretty sure that is not set up
35		$this->setConfigDir(app_dir . "/guiconfig");
36		
37		//	set the plugin directories
38		$this->addPluginsDir(dirname(__file__) . '/plugins');	//	one for plugins added into gui
39		$this->addPluginsDir(app_dir . "/guiplugins");			//	one or plugins specific to the app
40	}	
41}