From b9bb37f30dba98442d8b68bbadc647607bf265ee Mon Sep 17 00:00:00 2001 From: martinlanghoff Date: Fri, 20 May 2005 00:50:45 +0000 Subject: [PATCH] get_list_of_timezones() - backed out optimization in sorting at the database; we need to sort the translated names, not the db names. Thanks Jon for the heads up. --- lib/moodlelib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/moodlelib.php b/lib/moodlelib.php index e733a6d9d4e..ede7cd322ad 100644 --- a/lib/moodlelib.php +++ b/lib/moodlelib.php @@ -4495,7 +4495,7 @@ function get_list_of_timezones() { $timezones = array(); - if ($rawtimezones = get_records_sql('SELECT MAX(id), name FROM '.$CFG->prefix.'timezone GROUP BY name ORDER BY name ASC')) { + if ($rawtimezones = get_records_sql('SELECT MAX(id), name FROM '.$CFG->prefix.'timezone GROUP BY name')) { foreach($rawtimezones as $timezone) { if (!empty($timezone->name)) { $timezones[$timezone->name] = get_string(strtolower($timezone->name), 'timezones'); @@ -4506,7 +4506,7 @@ function get_list_of_timezones() { } } - // asort($timezones); + asort($timezones); for ($i = -13; $i <= 13; $i += .5) { $tzstring = 'GMT';