added folder_prefix option
authorlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Tue, 4 Apr 2000 01:26:06 +0000 (01:26 +0000)
committerlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Tue, 4 Apr 2000 01:26:06 +0000 (01:26 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@386 7612ce4b-ef26-0410-bec9-ea0150e637f0

src/load_prefs.php
src/options.php
src/options_submit.php

index 88ff334..27e3c13 100644 (file)
@@ -1,9 +1,10 @@
 <?
-   include("../config/config.php");
-
+   if (!isset($config_php))
+      include("../config/config.php");
    if (!isset($prefs_php))
       include("../functions/prefs.php");
-
+      
+   $load_prefs_php = true;
    checkForPrefs($data_dir, $username);
 
    $chosen_theme = getPref($data_dir, $username, "chosen_theme");
          $left_size = 200;
    }      
 
+   $folder_prefix = getPref($data_dir, $username, "folder_prefix");
+   if ($folder_prefix == "")
+      $folder_prefix = $default_folder_prefix;
+
    $editor_size = getPref($data_dir, $username, "editor_size");
    if ($editor_size == "")
       $editor_size = 76;
index a32ac0b..6ef3acc 100644 (file)
    echo "         <INPUT TYPE=TEXT NAME=reply_to VALUE=\"$replyto\" SIZE=50><BR>";
    echo "      </TD>";
    echo "   </TR>";
+   // DEFAULT FOLDERS 
+       if ($show_prefix_option == true) {
+      echo "   <TR>";
+          echo "      <TD WIDTH=20% ALIGN=RIGHT>";
+          echo           _("Folder path:");
+          echo "      </TD>";
+          echo "      <TD WIDTH=80% ALIGN=LEFT>";
+          if (isset ($folder_prefix))
+             echo "         <INPUT TYPE=TEXT NAME=folderprefix VALUE=\"$folder_prefix\" SIZE=50><BR>";
+          else   
+             echo "         <INPUT TYPE=TEXT NAME=folderprefix VALUE=\"$default_folder_prefix\" SIZE=50><BR>";
+          echo "      </TD>";
+          echo "   </TR>";
+   }   
    // THEME
    echo "   <TR>";
    echo "      <TD WIDTH=20% ALIGN=RIGHT>";
index 8960281..193cf26 100644 (file)
@@ -26,6 +26,7 @@
    setPref($data_dir, $username, "left_refresh", $leftrefresh);
    setPref($data_dir, $username, "language", $language);
    setPref($data_dir, $username, "left_size", $leftsize);
+   setPref($data_dir, $username, "folder_prefix", $folderprefix);
 
    setSig($data_dir, $username, stripslashes($signature_edit));