From: <ki...@us...> - 2007-09-05 16:13:21
|
Revision: 12672 http://squirrelmail.svn.sourceforge.net/squirrelmail/?rev=12672&view=rev Author: kink Date: 2007-09-05 09:13:18 -0700 (Wed, 05 Sep 2007) Log Message: ----------- bugfix: for a noselect-folder, skip the search, thanks Tomas Kuliavas Modified Paths: -------------- branches/SM-1_4-STABLE/squirrelmail/src/search.php Modified: branches/SM-1_4-STABLE/squirrelmail/src/search.php =================================================================== --- branches/SM-1_4-STABLE/squirrelmail/src/search.php 2007-09-04 09:33:10 UTC (rev 12671) +++ branches/SM-1_4-STABLE/squirrelmail/src/search.php 2007-09-05 16:13:18 UTC (rev 12672) @@ -508,15 +508,15 @@ for ($x=0;$x<$boxcount;$x++) { if (!in_array('noselect', $boxes[$x]['flags'])) { $mailbox = $boxes[$x]['unformatted']; + if (($submit == _("Search") || $submit == 'Search_no_update') && !empty($what)) { + sqimap_mailbox_select($imapConnection, $mailbox); + $msgs = sqimap_search($imapConnection, $where, $what, $mailbox, $color, 0, $search_all, $count_all); + $count_all = count($msgs); + printSearchMessages($msgs, $mailbox, $count_all, $imapConnection, + $where, $what, false, false); + array_push($perbox_count, $count_all); + } } - if (($submit == _("Search") || $submit == 'Search_no_update') && !empty($what)) { - sqimap_mailbox_select($imapConnection, $mailbox); - $msgs = sqimap_search($imapConnection, $where, $what, $mailbox, $color, 0, $search_all, $count_all); - $count_all = count($msgs); - printSearchMessages($msgs, $mailbox, $count_all, $imapConnection, - $where, $what, false, false); - array_push($perbox_count, $count_all); - } } for ($i=0;$i<count($perbox_count);$i++) { if ($perbox_count[$i]) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |