From 982566faa01977c3160cdb6707635f9b7f75c1e2 Mon Sep 17 00:00:00 2001 From: James Atkinson Date: Tue, 24 Jul 2001 22:11:24 +0000 Subject: System config admin section started. Can view settings but can't modify them at the moment git-svn-id: file:///svn/phpbb/trunk@750 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/functions.php | 144 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 144 insertions(+) (limited to 'phpBB/includes/functions.php') diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php index 98769d178b..7cb2c761d8 100644 --- a/phpBB/includes/functions.php +++ b/phpBB/includes/functions.php @@ -626,4 +626,148 @@ function sync($type, $id) } +function language_select($default, $dirname="language/") +{ + global $phpEx; + + $dir = opendir($dirname); + + $lang_select = "\n"; + + closedir($dir); + + return $lang_select; +} +// NOTE: This function should check is_dir($file), however the is_dir function seems to be buggy on my +// system so its not currently implemented that way +// - James +function template_select($default, $dirname = "templates") +{ + $dir = opendir($dirname); + + $template_select = ""; + + closedir($dir); + + return($template_select); +} +function theme_select($default) +{ + global $db, $board_config, $lang; + + $sql = "SELECT themes_id, themes_name + FROM " . THEMES_TABLE . " + WHERE themes_name LIKE '" . $board_config['default_template'] . "-%' + ORDER BY themes_name"; + if($result = $db->sql_query($sql)) + { + $num = $db->sql_numrows($result); + $rowset = $db->sql_fetchrowset($result); + + if($num) + { + $theme_select = "\n"; + } + else + { + $theme_select = ""; + } + } + else + { + message_die(GENERAL_ERROR, "Couldn't query themes table", "", __LINE__, __FILE__, $sql); + } + return($theme_select); +} +function tz_select($default) +{ + global $sys_timezone; + + if(!isset($default)) + { + $default == $sys_timezone; + } + $tz_select = "\n"; + + return($tz_select); +} + + ?> \ No newline at end of file -- cgit v1.2.1