Fixed it so that "viewing messages to 0" will never occur
authorlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Wed, 1 Dec 1999 18:44:11 +0000 (18:44 +0000)
committerlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Wed, 1 Dec 1999 18:44:11 +0000 (18:44 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@46 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/mailbox_display.php

index dafac53..4621169 100644 (file)
       /** This is the beginning of the message list table.  It wraps around all messages */
       echo "<TABLE WIDTH=100% BORDER=0 CELLPADDING=2 CELLSPACING=1>";
 
-      echo "<TR BGCOLOR=FFFFFF><TD>";
-      echo "<CENTER><FONT FACE=\"Arial,Helvetica\">Viewing messages <B>$startMessage</B> to <B>$endMessage</B> ($numMessages total)</FONT></CENTER>\n";
-      echo "</TD></TR>\n";
+      if ($startMessage < $endMessage) {
+         echo "<TR BGCOLOR=FFFFFF><TD>";
+         echo "<CENTER><FONT FACE=\"Arial,Helvetica\">Viewing messages <B>$startMessage</B> to <B>$endMessage</B> ($numMessages total)</FONT></CENTER>\n";
+         echo "</TD></TR>\n";
+      } else if ($startMessage == $endMessage) {
+         echo "<TR BGCOLOR=FFFFFF><TD>";
+         echo "<CENTER><FONT FACE=\"Arial,Helvetica\">Viewing message <B>$startMessage</B> ($numMessages total)</FONT></CENTER>\n";
+         echo "</TD></TR>\n";
+      }
 
       echo "<TR BGCOLOR=FFFFFF><TD>";
       if (($nextGroup <= $numMessages) && ($prevGroup >= 0)) {