|
From: Jon O. <jon...@us...> - 2008-02-17 12:54:58
|
Update of /cvsroot/mxbb/core/includes In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv19711 Modified Files: Tag: core28x mx_functions_style.php Log Message: Minor update to custom module default style *.cfg updated Index: mx_functions_style.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/mx_functions_style.php,v retrieving revision 1.17.2.14 retrieving revision 1.17.2.15 diff -C2 -d -r1.17.2.14 -r1.17.2.15 *** mx_functions_style.php 16 Feb 2008 20:15:31 -0000 1.17.2.14 --- mx_functions_style.php 17 Feb 2008 12:54:50 -0000 1.17.2.15 *************** *** 67,74 **** $style_path = $theme['template_name'] . '/'; ! if($filename=='index_body.tpl') ! { ! //die('hurra'); ! } // // Look at mxBB-Module folder.........................................................................mxBB-module --- 67,71 ---- $style_path = $theme['template_name'] . '/'; ! // // Look at mxBB-Module folder.........................................................................mxBB-module *************** *** 237,248 **** var $template_path = 'templates/'; ! var $template_name = '' ; var $template_names = array(); var $current_template_path = ''; ! var $cloned_template_name = '' ; var $cloned_current_template_path = ''; ! var $default_template_name = 'subSilver' ; var $default_current_template_path = ''; --- 234,245 ---- var $template_path = 'templates/'; ! var $template_name = ''; var $template_names = array(); var $current_template_path = ''; ! var $cloned_template_name = ''; var $cloned_current_template_path = ''; ! var $default_template_name = 'subSilver'; var $default_current_template_path = ''; *************** *** 537,542 **** $this->current_template_path = $this->template_path . $this->template_name; - $this->default_template_name = 'subSilver'; - $this->default_current_template_path = $this->template_path . $this->default_template_name; --- 534,537 ---- *************** *** 721,731 **** $cloned_template_path = $module_root_path . $this->cloned_current_template_path; $default_template_path = $module_root_path . $this->default_current_template_path; - $template_name = $this->template_name; ! if (file_exists($mx_root_path . $module_root_path . $this->current_template_path . '/' . $this->template_name . '.cfg')) ! { ! include($mx_root_path . $module_root_path . $this->current_template_path . '/' . $this->template_name . '.cfg'); ! } // --- 716,722 ---- $cloned_template_path = $module_root_path . $this->cloned_current_template_path; $default_template_path = $module_root_path . $this->default_current_template_path; $template_name = $this->template_name; ! @include($mx_root_path . $module_root_path . $this->current_template_path . '/' . $this->template_name . '.cfg'); // *************** *** 776,779 **** --- 767,776 ---- } + // + // What template is the module using? + // + $module_key = !empty($module_root_path) ? $module_root_path : 'subSilver'; + $this->template_names[$module_key] = $template_name; + unset($mx_images); } *************** *** 937,944 **** // Hack for modern modules, with non-subSilver default template // ! if (!empty($this->default_module_style) && $this->default_module_style != $this->default_template_name) { - $this->default_current_template_path = 'templates/' . $this->default_module_style . '/'; $this->default_template_name = $this->default_module_style; } --- 934,941 ---- // Hack for modern modules, with non-subSilver default template // ! if (!empty($this->default_module_style) ) { $this->default_template_name = $this->default_module_style; + $this->default_current_template_path = 'templates/' . $this->default_template_name; } *************** *** 950,955 **** if (!empty($this->default_module_style)) { - $this->default_current_template_path = ''; $this->default_template_name = 'subSilver'; $this->default_module_style = ''; } --- 947,952 ---- if (!empty($this->default_module_style)) { $this->default_template_name = 'subSilver'; + $this->default_current_template_path = 'templates/' . $this->default_template_name; $this->default_module_style = ''; } |