Getting ready for 1.2.0 release.
[squirrelmail.git] / src / options_display.php
index 2e03483ef3cb563331389d4920e4b8caeb592157..75184af5c7a4706eadce28ec835832fcd46ee068 100644 (file)
@@ -1,15 +1,15 @@
 <?php
 
-   /**
   **  options_display.php
   **
   **  Copyright (c) 1999-2001 The SquirrelMail Development Team
   **  Licensed under the GNU GPL. For full terms see the file COPYING.
   **
   **  Displays all optinos about display preferences
   **
   **  $Id$
   */
+/**
* options_display.php
+ *
* Copyright (c) 1999-2002 The SquirrelMail Project Team
* Licensed under the GNU GPL. For full terms see the file COPYING.
+ *
* Displays all optinos about display preferences
+ *
* $Id$
+ */
 
 /* Define the group constants for the display options page. */
 define('SMOPT_GRP_GENERAL', 0);
@@ -35,8 +35,10 @@ function load_optpage_data_display() {
     /* Load the theme option. */
     $theme_values = array();
     foreach ($theme as $theme_key => $theme_attributes) {
-        $theme_values[$theme_attributes['PATH']] = $theme_attributes['NAME'];
+        $theme_values[$theme_attributes['NAME']] = $theme_attributes['PATH'];
     }
+    ksort($theme_values);
+    $theme_values = array_flip($theme_values);
     $optvals[SMOPT_GRP_GENERAL][] = array(
         'name'    => 'chosen_theme',
         'caption' => _("Theme"),
@@ -46,7 +48,7 @@ function load_optpage_data_display() {
         'save'    => 'save_option_theme'
     );
 
-    $language_values = array();
+    $language_values = array('');
     foreach ($languages as $lang_key => $lang_attributes) {
         if (isset($lang_attributes['NAME'])) {
             $language_values[$lang_key] = $lang_attributes['NAME'];