From bba815c54136c2c6e3355557c15232f4e206e4ed Mon Sep 17 00:00:00 2001 From: Janusz Dobrowolski Date: Tue, 11 Mar 2008 21:07:42 +0000 Subject: [PATCH] Changed list of themes and list of themes acording to config.php changes --- includes/ui/ui_lists.inc | 29 +++++++++++++++++++++-------- 1 file changed, 21 insertions(+), 8 deletions(-) diff --git a/includes/ui/ui_lists.inc b/includes/ui/ui_lists.inc index 6932d5aa..f271bb65 100644 --- a/includes/ui/ui_lists.inc +++ b/includes/ui/ui_lists.inc @@ -1050,6 +1050,7 @@ function stock_units_list_row($label, $name, $value, $enabled=true) { global $stock_units; + $result = get_all_item_units(); echo "$label\n"; if ($enabled) echo "\n"; @@ -1959,8 +1963,17 @@ function decseps_list_row($label, $name, $value) function themes_list_row($label, $name, $value) { - global $themes; - + global $path_to_root; + + $path = $path_to_root.'/themes/'; + $themes = array(); + $themedir = opendir($path); + while(false !== ($fname = readdir($themedir))) { + if($fname!='.' && $fname!='..' && $fname!='CVS' && is_dir($path.$fname)) { + $themes[] = $fname; + } + } + sort($themes); echo "$label\n"; echo "