Added images used for $advanced_tree=true in src/left_main.php
[squirrelmail.git] / config / conf.pl
index ac66f4206bab1f2d77a785eaf36b6edff2ac16de..b601f4772572722203a2d6e7d1c5c8f47af9186a 100755 (executable)
@@ -246,7 +246,7 @@ while ( $line = <FILE> ) {
     }
 }
 close FILE;
-if ( $useSendmail ne "true" ) {
+if ( lc($useSendmail) ne "true" ) {
     $useSendmail = "false";
 }
 if ( !$sendmail_path ) {
@@ -1764,39 +1764,43 @@ sub command214 {
 
 # Automatically delete folders 
 sub command215 {
-    if ( $imap_server_type == "courier" ) {
-        print "Courier(or Courier-IMAP) IMAP servers do not support ";
-        print "subfolders of Trash. \n";
-        print "Deleting folders will bypass the trash folder and ";
-        print "be immediately deleted.\n\n";
-        print "If this is not the correct value for your server,\n";
-        print "please use option D on the Main Menu to configure your server correctly.\n\n";
-        print "Press any key to continue...\n";
-        $new_delete = <STDIN>;
-        $delete_folder = "true";
-    } elsif ( $imap_server_type == "uw" ) {
-        print "UW IMAP servers will not allow folders containing";
-        print "mail to also contain folders.\n";
-        print "Deleting folders will bypass the trash folder and";
-        print "be immediately deleted\n\n";
+    if ( $imap_server_type eq "uw" ) {
+        print "UW IMAP servers will not allow folders containing mail to also contain folders.\n";
+        print "Deleting folders will bypass the trash folder and be immediately deleted\n\n";
         print "If this is not the correct value for your server,\n";
         print "please use option D on the Main Menu to configure your server correctly.\n\n";
         print "Press any key to continue...\n";
         $new_delete = <STDIN>;
         $delete_folder = "true";
     } else { 
-        print "Should folders selected for deletion bypass the Trash folder?\n\n";
+        if ( $imap_server_type eq "courier" ) {
+            print "Courier (or Courier-IMAP) IMAP servers may not support ";
+            print "subfolders of Trash. \n";
+            print "Specifically, if Courier is set to always move messages to Trash, \n";
+            print "Trash will be treated by Courier as a special folder that does not \n";
+            print "allow subfolders. \n\n";
+            print "Please verify your Courier configuration, and test folder deletion \n";
+            print "when changing this setting.\n\n";                                                             
+        }
+
+        print "Are subfolders of the Trash supported by your IMAP server?\n";
+        print "If so, should deleted folders be sent to Trash?\n";
+        print "If not, say no (deleted folders should not be sent to Trash)\n\n";
+        # reversal of logic.
+        # question was: Should folders be automatically deleted instead of sent to trash..
+        # we've changed the question to make it more clear, 
+        # and are here handling that to avoid changing the answers.. 
         if ( lc($delete_folder) eq "true" ) {
-            $default_value = "y";
-        } else {
             $default_value = "n";
+        } else {
+            $default_value = "y";
         }
-        print "Auto delete folders? (y/n) [$WHT$default_value$NRM]: $WHT";
+        print "Send deleted folders to Trash? (y/n) [$WHT$default_value$NRM]: $WHT";
         $new_delete = <STDIN>;
         if ( ( $new_delete =~ /^y\n/i ) || ( ( $new_delete =~ /^\n/ ) && ( $default_value eq "y" ) ) ) {
-            $delete_folder = "true";
-        } else {
             $delete_folder = "false";
+        } else {
+            $delete_folder = "true";
         }
     }
     return $delete_folder;
@@ -2925,6 +2929,7 @@ sub set_defaults {
             $show_contain_subfolders_option = false;
             $optional_delimiter             = ".";
             $disp_default_folder_prefix     = "<none>";
+            $force_username_lowercase       = false;
 
             $continue = 1;
         } elsif ( $server eq "uw" ) {
@@ -2939,6 +2944,7 @@ sub set_defaults {
             $optional_delimiter             = "/";
             $disp_default_folder_prefix     = $default_folder_prefix;
             $delete_folder                  = true;
+            $force_username_lowercase       = true;
             
             $continue = 1;
         } elsif ( $server eq "exchange" ) {
@@ -2952,6 +2958,7 @@ sub set_defaults {
             $show_contain_subfolders_option = false;
             $optional_delimiter             = "detect";
             $disp_default_folder_prefix     = "<none>";
+            $force_username_lowercase       = true;
 
             $continue = 1;
         } elsif ( $server eq "courier" ) {
@@ -2966,6 +2973,7 @@ sub set_defaults {
             $optional_delimiter             = ".";
             $disp_default_folder_prefix     = $default_folder_prefix;
             $delete_folder                  = true;
+            $force_username_lowercase       = false;
             
             $continue = 1;
         } elsif ( $server eq "macosx" ) {
@@ -3000,8 +3008,9 @@ sub set_defaults {
         print "show_contain_subfolders_option = $show_contain_subfolders_option\n";
         print "            optional_delimiter = $optional_delimiter\n";
         print "                 delete_folder = $delete_folder\n";
+        print "      force_username_lowercase = $force_username_lowercase\n";
     }
-    print "\nPress any key to continue...";
+    print "\nPress enter to continue...";
     $tmp = <STDIN>;
 }