Menu

#12 folder list out of order

open
nobody
None
5
2008-02-16
2008-02-16
No

Hi,

the folder list is out of order. The different subfolders are mixed and not chown at the right place. I tried to fix it, see the patch

--- recipie_functions.php_old 2008-02-16 19:29:14.000000000 +0100
+++ recipie_functions.php_changed 2008-02-16 19:26:58.000000000 +0100
@@ -46,22 +46,11 @@
*/
function folderDropdown($str)
{
- global $folders;
-
- echo '<select name="folder">' . "\n";
-
- foreach ($folders as $foldervalue => $foldername)
- {
- // FIXME: you still have to htmlspecialchar both
- // and undo htmlspecialchars in posted folder name.
- echo "<option value=\"$foldervalue\"";
- if ($foldervalue == $str)
- echo ' selected';
- echo '>' . $foldername . '</option>' . "\n";
- }
-
- echo '</select>' . "\n";
- }
+ require_once(SM_PATH . 'functions/mailbox_display.php');
+ echo ' <small>&nbsp;<tt><select name="targetMailbox">';
+ echo sqimap_mailbox_option_list($imapConnection, array(strtolower($str)) );
+ echo ' </select></tt>&nbsp;';
+ }

The file I changed is attached.

Discussion

  • Julian Dittrich

    Julian Dittrich - 2008-02-16

    recipie_functions.php

     
  • Paul Lesniewski

    Paul Lesniewski - 2010-10-01

    This is a known shortcoming of the way SquirrelMail returns its folder list for when you are allowing users to create filters with folders that are not subscribed to. If you find that version 2.0 has the same deficiency, we'd love to look at an updated patch. Thank you.

     
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.