X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=src%2Fread_body.php;h=fa386594bbeab12ec99ddd965e798aa1fb09b6ce;hb=6f927fceb563eb7461ac9fd3604e9efe14fdf9ad;hp=287b275209dd01f776c957607cbb0898cfbfcce6;hpb=6ee631f7b92f6a205e0841ac40e6b0e763a5a734;p=squirrelmail.git diff --git a/src/read_body.php b/src/read_body.php index 287b2752..fa386594 100644 --- a/src/read_body.php +++ b/src/read_body.php @@ -1,407 +1,886 @@ '; - echo '
';
-
- $cnum = 0;
- for ($i=1; $i < count($read)-1; $i++) {
- $line = htmlspecialchars($read[$i]);
- if (eregi("^>", $line)) {
- $second[$i] = $line;
- $first[$i] = ' ';
- $cnum++;
- } else if (eregi("^[ |\t]", $line)) {
- $second[$i] = $line;
- $first[$i] = '';
- } else if (eregi("^([^:]+):(.+)", $line, $regs)) {
- $first[$i] = $regs[1] . ':';
- $second[$i] = $regs[2];
- $cnum++;
- } else {
- $second[$i] = trim($line);
- $first[$i] = '';
- }
- }
- for ($i=0; $i < count($second); $i = $j) {
- if (isset($first[$i]))
- $f = $first[$i];
- if (isset($second[$i]))
- $s = nl2br($second[$i]);
- $j = $i + 1;
- while ($first[$j] == '' && $j < count($first)) {
- $s .= ' ' . nl2br($second[$j]);
- $j++;
- }
- parseEmail($s);
- if (isset($f)) echo " |