- $template_config_file = SM_PATH . $this->get_template_file_directory()
- . 'config.php';
- if (!file_exists($template_config_file)) {
-
- trigger_error('No template configuration file was found where expected: ("'
- . $template_config_file . '")', E_USER_ERROR);
-
- } else {
-
- require($template_config_file);
-
-
- // instantiate and set up Smarty object
- //
-//LEFT OFF HERE - check for this as empty or not
- require($smarty_path);
- $this->smarty_template = new Smarty();
-//LEFT OFF HERE - check for these as empty or not.... I think we at least need compile dir?
- $this->smarty_template->compile_dir = $smarty_compile_dir;
- $this->smarty_template->cache_dir = $smarty_cache_dir;
- $this->smarty_template->config_dir = $smarty_config_dir;
-
- // note that we do not use Smarty's template_dir
- // because SquirrelMail has its own method of
- // determining template file paths
- //
- //$this->smarty_template->template_dir =
-
- }
+ // instantiate and set up Smarty object
+ //
+ $smarty_path
+ = Template::get_template_config($this->template_set_id, 'smarty_path');
+ require($smarty_path);
+ $this->smarty_template = new Smarty();
+ $this->smarty_template->compile_dir
+ = Template::get_template_config($this->template_set_id, 'smarty_compile_dir');
+ $this->smarty_template->cache_dir
+ = Template::get_template_config($this->template_set_id, 'smarty_cache_dir');
+ $this->smarty_template->config_dir
+ = Template::get_template_config($this->template_set_id, 'smarty_config_dir');
+
+ // note that we do not use Smarty's template_dir
+ // because SquirrelMail has its own method of
+ // determining template file paths
+ //
+ //$this->smarty_template->template_dir =