From 0cd84d75b1d2c786b88c859a049443669b37d96d Mon Sep 17 00:00:00 2001 From: fidian Date: Sat, 10 Feb 2001 01:22:06 +0000 Subject: [PATCH] * Removed the unnecessary function replace_escaped_spaces (never used) * Changed all instances of replace_spaces to the actual function call (removing the silly wrapper function replace_spaces) * Added a collapseable folder list for left_main.php * Added the option for it under Options -> Folders (Sorry that I didn't do this in smaller commits that only did one or two of the above actions.) git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@1110 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- ChangeLog | 1 + functions/mailbox_display.php | 2 +- functions/strings.php | 7 +- src/folders.php | 10 +-- src/left_main.php | 143 ++++++++++++++++++++++++---------- src/load_prefs.php | 2 + src/options.php | 5 +- src/options_folder.php | 22 ++++-- src/search.php | 2 +- 9 files changed, 132 insertions(+), 62 deletions(-) diff --git a/ChangeLog b/ChangeLog index c1d693e4..f8ca3d0d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,7 @@ Version 1.0.3 -- DEVELOPMENT ---------------------------- - Made folder drop-down list consistant in look to the other drop-downs +- Added collapseable folder listing (an option that can be turned on) Version 1.0.2 -- February 8, 2001 --------------------------------- diff --git a/functions/mailbox_display.php b/functions/mailbox_display.php index 44f502f0..afb0549d 100644 --- a/functions/mailbox_display.php +++ b/functions/mailbox_display.php @@ -512,7 +512,7 @@ for ($i = 0; $i < count($boxes); $i++) { if (!in_array("noselect", $boxes[$i]['flags'])) { $box = $boxes[$i]['unformatted']; - $box2 = replace_spaces($boxes[$i]['unformatted-disp']); + $box2 = str_replace(' ', ' ', $boxes[$i]['unformatted-disp']); echo " \n"; } } diff --git a/functions/strings.php b/functions/strings.php index 1048f680..bac77cb2 100644 --- a/functions/strings.php +++ b/functions/strings.php @@ -232,7 +232,7 @@ function getLineOfAddrs($array) { if (is_array($array)) { $to_line = implode(', ', $array); - $to_line = trim(ereg_replace(',,+', ',', $to_line)); + $to_line = trim(ereg_replace(', (, )+', ', ', $to_line)); } else { $to_line = ''; } @@ -300,14 +300,11 @@ } + // Depreciated. :-) I always wanted to say that. function replace_spaces ($string) { return str_replace(' ', ' ', $string); } - function replace_escaped_spaces ($string) { - return str_replace(' ', ' ', $string); - } - function get_location () { # This determines the location to forward to relative # to your server. If this doesnt work correctly for diff --git a/src/folders.php b/src/folders.php index a3acfa81..846220a3 100644 --- a/src/folders.php +++ b/src/folders.php @@ -132,7 +132,7 @@ strtolower($boxes[$i]["unformatted"]) != "inbox.trash")) { $box = $boxes[$i]["unformatted-dm"]; - $box2 = replace_spaces($boxes[$i]["unformatted-disp"]); + $box2 = str_replace(' ', ' ', $boxes[$i]["unformatted-disp"]); echo "