Index: src/admin/includes/functions/general.php IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== --- src/admin/includes/functions/general.php (revision 8e567ee09be420087289b294f86310452df0093a) +++ src/admin/includes/functions/general.php (revision ) @@ -1985,16 +1985,25 @@ function xtc_cfg_pull_down_template_sets() { $name = (($key) ? 'configuration[' . $key . ']' : 'configuration_value'); - $dir = opendir(DIR_FS_CATALOG . 'templates/'); + $t_template_base_dir = DIR_FS_CATALOG . 'templates/'; + $dir = opendir($t_template_base_dir); if($dir) { while(($templates = readdir($dir)) !== false) { - if($templates != "CVS" and $templates != "." and $templates != "..") + if($templates != "CVS" and $templates != "." and $templates != ".." and $templates != "MobileCandy") { - if(is_dir(DIR_FS_CATALOG . 'templates/' . "//" . $templates)) + $t_template_dir = $t_template_base_dir . "//" . $templates; + if(is_dir($t_template_dir) && file_exists($t_template_dir."/template_settings.php")) { + include($t_template_dir."/template_settings.php"); + if(is_array($t_template_settings_array) && array_key_exists('TEMPLATE_PRESENTATION_VERSION',$t_template_settings_array)) + { + if($t_template_settings_array['TEMPLATE_PRESENTATION_VERSION'] >= 2.0) + { - $templates_array[] = array('id' => $templates, 'text' => $templates); + $templates_array[] = array('id' => $templates, 'text' => $templates); + } + } } } } \ No newline at end of file