X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=blobdiff_plain;f=src%2Fview_header.php;h=9c924a3d4e1e1b990b642104c3f1efea038577a6;hp=fd43a16af92ebd5ad165e1af049ef2c674dba0e8;hb=39790db7cdf3a4705e169e4f57450449ae23b570;hpb=d4e46166df04792c6b939356ea5dfda8e47bba7b diff --git a/src/view_header.php b/src/view_header.php index fd43a16a..9c924a3d 100644 --- a/src/view_header.php +++ b/src/view_header.php @@ -5,7 +5,7 @@ * * This is the code to view the message header. * - * @copyright © 1999-2009 The SquirrelMail Project Team + * @copyright 1999-2009 The SquirrelMail Project Team * @license http://opensource.org/licenses/gpl-license.php GNU Public License * @version $Id$ * @package squirrelmail @@ -41,16 +41,17 @@ function parse_viewheader($imapConnection,$id, $passed_ent_id) { for ($i=1; $i < count($read); $i++) { $line = htmlspecialchars($read[$i]); switch (true) { - case (eregi("^>", $line)): + case (preg_match('/^>/i', $line)): $second[$i] = $line; $first[$i] = ' '; $cnum++; break; - case (eregi("^[ |\t]", $line)): +// FIXME: is the pipe character below a mistake? I think the original author might have thought it carried special meaning in the character class, which it does not... but then again, I am not currently trying to understand what this code actually does + case (preg_match('/^[ |\t]/', $line)): $second[$i] = $line; $first[$i] = ''; break; - case (eregi("^([^:]+):(.+)", $line, $regs)): + case (preg_match('/^([^:]+):(.+)/', $line, $regs)): $first[$i] = $regs[1] . ':'; $second[$i] = $regs[2]; $cnum++;