- echo '<tr bgcolor="' . $message_highlight_list[$i]['color'] . '">'.
- "<td width=20% bgcolor=\"$color[4]\" nobr>".
- "<small>[<a href=\"options_highlight.php?action=edit&theid=$i\">".
- _("Edit") .
- '</a>] [<a href="options_highlight.php?action=delete&theid='.
- $i . '">' . _("Delete") . '</a>]</small>'.
- '</td><td>'.
- htmlspecialchars($message_highlight_list[$i]['name']) .
- '</td><td>'.
- $message_highlight_list[$i]['match_type'] . ' = ' .
- htmlspecialchars($message_highlight_list[$i]['value']).
- '</td></tr>';
+ $match_type = '';
+ switch ($message_highlight_list[$i]['match_type'] ) {
+ case 'from' :
+ $match_type = _("From");
+ break;
+ case 'to' :
+ $match_type = _("To");
+ break;
+ case 'cc' :
+ $match_type = _("Cc");
+ break;
+ case 'to_cc' :
+ $match_type = _("To or Cc");
+ break;
+ case 'subject' :
+ $match_type = _("subject");
+ break;
+ }
+
+ echo html_tag( 'tr',
+ html_tag( 'td',
+ '<small>[<a href="options_highlight.php?action=edit&theid=' . $i . '">' .
+ _("Edit") .
+ '</a>] [<a href="options_highlight.php?action=delete&theid='.
+ $i . '">' . _("Delete") . '</a>]</small>' ,
+ 'left', $color[4], 'width="20%" nowrap' ) .
+ html_tag( 'td',
+ htmlspecialchars($message_highlight_list[$i]['name']) ,
+ 'left' ) .
+ html_tag( 'td',
+ $match_type . ' = ' .
+ htmlspecialchars($message_highlight_list[$i]['value']) ,
+ 'left' ) ,
+ '', $message_highlight_list[$i]['color'] ) . "\n";