case 4: /* subject */
echo " <td bgcolor=\"$hlt_color\">$bold";
if ($thread_sort_messages == 1) {
- echo str_repeat(" ",$indent_array[$msg["ID"]]);
- }
+ if (isset($indent_array[$msg["ID"]])) {
+ echo str_repeat(" ",$indent_array[$msg["ID"]]);
+ }
+ }
echo "<a href=\"read_body.php?mailbox=$urlMailbox&passed_id="
. $msg["ID"]
. "&startMessage=$start_msg&show_more=0$search_stuff\"";
echo '<b><small><center><font color=red>Thread sorting is not'.
' supported by your IMAP server.<br>Please report this'.
'to the system administrator.</center></small></b>';
- $thread_sort_messages == 0;
+ $thread_sort_messages = 0;
$id = array();
}
else {
'is not supported by your IMAP server.<br>Please report this'.
' to the system administrator.</center></small></b>';
$sort = $server_sort_order;
- $allow_server_sort = false;
+ $allow_server_sort = FALSE;
$id = array();
}
else {
. "</TD>\n"
. " </TR>\n";
-/* draws thread sorting links */
+ /* draws thread sorting links */
if ($allow_thread_sort == TRUE) {
if ($thread_sort_messages == 1 ) {
$set_thread = 2;
} else {
echo ' <TD WIDTH="25%"><B>' . _("From") . '</B>';
}
- if ($thread_sort_messages != 1) {
+ if ($allow_thread_sort != TRUE || $thread_sort_messages != 1) {
ShowSortButton($sort, $mailbox, 2, 3);
}
echo "</TD>\n";
break;
case 3: /* date */
echo ' <TD NOWRAP WIDTH="5%"><B>' . _("Date") . '</B>';
- if ($thread_sort_messages != 1) {
+ if ($allow_thread_sort != TRUE || $thread_sort_messages != 1) {
ShowSortButton($sort, $mailbox, 0, 1);
}
echo "</TD>\n";
break;
case 4: /* subject */
echo ' <TD><B>' . _("Subject") . '</B> ';
- if ($thread_sort_messages != 1) {
+ if ($allow_thread_sort != TRUE || $thread_sort_messages != 1) {
ShowSortButton($sort, $mailbox, 4, 5);
}
echo "</TD>\n";
. '&what=' . urlencode($what);
}
- if ($PG_SHOWNUM == 999999) {
- $result .= '&PG_SHOWNUM=999999';
- }
-
$result .= "\">";
if (isset($checkall) && ($checkall == '1')) {
}
}
} else if ($PG_SHOWNUM == 999999) {
- $pg_str = "<A HREF=\"right_main.php?use_mailbox_cache=$use"
- . "&startMessage=1&mailbox=$box\" TARGET=\"right\">"
- . _("Paginate") . '</A>' . $spc;
+ $pg_str = "<A HREF=\"right_main.php?PG_SHOWALL=0"
+ . "&use_mailbox_cache=$use&startMessage=1&mailbox=$box\" "
+ . "TARGET=\"right\">" ._("Paginate") . '</A>' . $spc;
}
/* If necessary, compute the 'show all' string. */
if (($prv_str != '') || ($nxt_str != '')) {
- $all_str = "<A HREF=\"right_main.php?PG_SHOWNUM=999999"
+ $all_str = "<A HREF=\"right_main.php?PG_SHOWALL=1"
. "&use_mailbox_cache=$use&startMessage=1&mailbox=$box\" "
. "TARGET=\"right\">" . _("Show All") . '</A>';
}