Continuation of fixing the alternating row colors in addressbook:
authorkink <kink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Sat, 19 Jun 2004 11:13:30 +0000 (11:13 +0000)
committerkink <kink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Sat, 19 Jun 2004 11:13:30 +0000 (11:13 +0000)
this code is present at 3 different places...

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

src/addrbook_search.php
src/addrbook_search_html.php

index 2fbd9346b660fe680d9f2be3ce42da421ec5335b..c62e112b6aa9d959852e012d1c25bcd1f5df94d2 100644 (file)
@@ -136,9 +136,12 @@ function display_result($res, $includesource = true) {
     echo "</tr>\n";
     
     while (list($undef, $row) = each($res)) {
-        $tr_bgcolor = '';
         $email = htmlspecialchars(addcslashes(AddressBook::full_address($row), "'"), ENT_QUOTES);
-        if ($line % 2) { $tr_bgcolor = $color[0]; }
+        if ($line % 2) { 
+            $tr_bgcolor = $color[12];
+        } else {
+            $tr_bgcolor = $color[4];
+        }
         echo html_tag( 'tr', '', '', $tr_bgcolor, 'nowrap' ) .
         html_tag( 'td',
              '<small><a href="javascript:to_address(' . 
index 81997272da00d67e403b94e26d6f1d7c3063f3fd..1e0f8f45d170ec39386e773496f9449109c3404e 100644 (file)
@@ -111,9 +111,12 @@ if ($javascript_on) {
     echo "</tr>\n";
 
     foreach ($res as $row) {
-        $tr_bgcolor = '';
         $email = AddressBook::full_address($row);
-        if ($line % 2) { $tr_bgcolor = $color[0]; }
+        if ($line % 2) { 
+            $tr_bgcolor = $color[12];
+        } else {
+            $tr_bgcolor = $color[4];
+        }
         if ($squirrelmail_language == 'ja_JP')
             {
         echo html_tag( 'tr', '', '', $tr_bgcolor, 'nowrap' ) .