Swap colors, because new %2 test by Jon is true when the number is NOT
authorkink <kink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 27 Feb 2003 11:13:36 +0000 (11:13 +0000)
committerkink <kink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 27 Feb 2003 11:13:36 +0000 (11:13 +0000)
dividable by 2 (3%2=1) so to keep the old color for one '>' we need to
swap the colors.

git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@4561 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/mime.php

index 64e38ba74d81acc6ec35f57fccbe7ef431363425..48866d6dff9a16853b566c7fe8d7612458cc48aa 100644 (file)
@@ -292,15 +292,15 @@ function translateText(&$body, $wrap_at, $charset) {
         }
 
         if ($quotes % 2) {
         }
 
         if ($quotes % 2) {
-            if (!isset($color[14])) {
-                $color[14] = '#FF0000';
-            }
-            $line = '<FONT COLOR="' . $color[14] . '">' . $line . '</FONT>';
-        } elseif ($quotes) {
             if (!isset($color[13])) {
                 $color[13] = '#800000';
             }
             if (!isset($color[13])) {
                 $color[13] = '#800000';
             }
-            $line = '<FONT COLOR="' . $color[13] . '">' . $line . '</FONT>';
+            $line = '<font color="' . $color[13] . '">' . $line . '</font>';
+        } elseif ($quotes) {
+            if (!isset($color[14])) {
+                $color[14] = '#FF0000';
+            }
+            $line = '<font color="' . $color[14] . '">' . $line . '</font>';
         }
 
         $body_ary[$i] = $line;
         }
 
         $body_ary[$i] = $line;